In most cases, yes. Assuming that you don't have certain complications, having sex shouldn't pose a risk to you or your baby. Your baby is surrounded and cushioned by amniotic fluid, and protected by your uterus and a layer of muscles.
//In addition, the mucus plug inside your cervix helps guard against infection. (It's not impenetrable, though, so if you or your partner has sex with other people, you need to use condoms to protect yourself – and your baby – from sexually transmitted infections.)
However, in certain circumstances, you may have to modify your activity or abstain from sex altogether for part or all of your pregnancy.
Your caregiver will tell you to abstain from sex if you have:
There are other situations in which your healthcare practitioner may advise you to not to have sex. For example, if you had a spontaneous preterm birth in a previous pregnancy, she will probably advise you to stop having sex at some point during the second or third trimester and to remain abstinent until you reach 37 weeks.
Whatever your situation, don't be shy about talking about sex with your practitioner. If she has advised you not to have sex, be sure you understand whether she's talking specifically about intercourse, or about putting anything in your vagina, or about any activity that may bring you to orgasm. (Orgasm can cause mild uterine contractions, as can nipple stimulation and the prostaglandins in semen.)
And, of course, if you notice any unusual symptoms during or following intercourse, such as pain or discharge, be sure to let your practitioner know. If you can't have sex, explore other ways of expressing your love: Cuddle, kiss, give each other long massages, and share your feelings for each other.