Losing Mucus Plug. When you become pregnant, your body undergoes a multitude of changes and adjustments to accommodate the baby in your womb. One of these changes is your mucus plug. Its purpose is to protect your baby from bacterial infections by creating a barrier near your cervix opening.