There is myth (specifically in rural part of India) about papaya that it is not safe to eat during pregnancy, because it causes miscarriage and stillbirth sometime.
If papaya is unripe then its not safe to eat. Because unripe papaya contains a substance called latex, and this latex may trigger uterine contractions which leads miscarriage.
But fully ripened papaya is a good source of sodium, potassium, vitamins with no cholesterol so it is safe to use papaya during pregnancy, because papaya help to reduce the constipation and heartburn which is a common problem during pregnancy. So many expert suggest to eat ripened papaya to the pregnant woman.
Papaya contains an enzyme called papain that helps in digestion.This papain is found in fruits latex and leaves. So this latex of unripe papaya acts like prostaglandin and oxytocin which is also responsible for starting labour pain (doctors use synthetic prostaglandin and oxytocin to artificially induce labor pain).
An unripe or semi ripe papaya should completely be avoided during pregnancy, and fully ripe papaya should be used only on doctor’s recommendation in very small amount.