In general, you will be examined as you get close to your due date (or past it) or if you think you might be in labor.
A cervical exam is when your doctor or midwife inserts two fingers into your vagina to assess your cervix. This can be done at a prenatal visit if you are having contractions or are close to your due date or when you are in labor to see how your labor is progressing.
While doctors and midwives each have their own practice patterns, most will not check your cervix until you are at or just before your due date. Some may routinely start checking once you are term (at 37 weeks of pregnancy), but if you do not want to be examined and there are no concerns, you can decline. Additionally, if you are complaining of regular contractions at any time during your pregnancy, a cervical exam can be done to see if you might be in labor.