Ancient Egypt was a remarkably advanced society. They had one of the first known written languages, the earliest form of paper, a 365-day calendar, toothpaste, and breath mints. Egyptians even invented eye makeup as far back as 4000 BC by combining soot and galena to create kohl. It was worn by both men and women for status as well to protect the wearer from the evil eye.
Preferring small families, they also invented enough different methods of contraception that you’d be forgiven for wondering if someone in a TARDIS gifted them with the secrets of the universe (or at least a modern health textbook).
For those who were really serious about avoiding pregnancy, hieroglyphs from the second century CE recommend castration for either gender. Surgeries such as the ovariotomy (the removal of the ovaries) were also available, if mercifully rare.
Most people depended on much less invasive forms of contraception. One of the most common was spermicide administered in a sort of tampon made of linen and soaked in acidic oils. Some minerals found in the water also had spermicidal properties when mixed with sour milk, which had the added benefit of making the vagina more acidic to make conception less likely.
Pessaries blocking the entrance to the cervix altogether could be made from the sap of the acacia tree, another natural substance with proven spermicidal properties. The modern equivalent of this would be using a diaphragm with nonoxynol-9. For a back-up method, certain plant extracts could be eaten to alter hormonal balance and inhibit ovulation, much like the birth control pills used today.
For the more adventurous woman, a medical papyrus from 1850 BCE assures us that: “Crocodile dung mixed with honey and placed in the vagina of a woman prevents contraception…”
I can only assume that this one worked by putting all parties off of sex altogether.
Unfortunately, the Egyptians had not yet invented statistics to help us to quantify the success rate of these methods, but in the event that they failed, the recipes for herbal abortificients were passed down from generation to generation.
If all of this isn’t mind-blowing enough, the Egyptians even had the first urine-based pregnancy test. Women were told to pee on some barley and emmer every day and if they grew, she was pregnant. Amazingly enough, modern tests have actually confirmed that this was a fairly accurate way to detect pregnancy.
Sadly, this kind of pregnancy test fell into disuse and the next one was not introduced until 1929.
Condoms even existed, but they were more for show than contraception. Many have been found in the tombs of aristocrats for use in the next world. Fully prepared for one crazy party, they were entombed with sheaths made of animal skin dyed bright colors and trimmed in fur.
Also strap-ons made of mother of pearl. You know, just in case.