It is generally recommended that you avoid taking any medications you have not been prescribed during your pregnancy.
While some medications are safe to take during pregnancy. But others are not, or their effects on your baby may not be known. When confirmed you're pregnant, your doctor will suggest what meds are OK to take and what meds you need to find alternatives for.