While it's rare, mastitis can occur during pregnancy. This is often due to changes in breast tissue as your body prepares for lactation. If you suspect mastitis during pregnancy, it's essential to consult a healthcare professional for guidance.