Alyssa Milano revealed Monday that she has had two abortions on an episode of her podcast Alyssa Milano: Sorry Not Sorry—and it turns out, she underwent both after getting pregnant while taking birth control pills. 

Milano, 46, said both abortions were performed more than 25 years ago, according to PeopleAnd she said that choosing to have an abortion the first time she found out she was pregnant was excruciating. “It was not an easy choice. It was not something I wanted, but it was something that I needed, like most health care is.”

A few months after her first abortion, Milano learned she was pregnant again, and chose to have a second abortion—putting an emphasis on the fact that she had a choice in the matter. “I chose. It was my choice. And it was absolutely the right choice for me,” Milano said. She added that she had tried to avoid becoming pregnant by taking birth control pills, which failed her. “I had done what I knew to do to prevent pregnancy and was still pregnant.”

RELATED: 

Wait, can you really get pregnant on the pill?

To be clear, preventing pregnancy isn't the only reason many women take the pill, but it's definitely a huge contributing factor—and unexpected pregnancies while taking birth control pills definitely do happen, Christine Greves, MD, an Orlando-based ob-gyn, tells Health.

Why? According to Dr. Greves, it all boils down to how dedicated you are to taking the pill—at the same time every single day. It's called "perfect use" versus "typical use," according to Planned Parenthood. With perfect use (again, taking the Pill at the same time, every day), the pill is 99 percent effective. But let's face it: You're not perfect, and neither is your usage. With "typical use" (like, if you miss a pill one night, at least once a month), the pill's effectiveness drops to 91 percent. That means nine out of 100 people each year get pregnant while on the pill, per Planned Parenthood. 

It's also important to note that there are two types of birth control pills: progestin-only pills, sometimes called mini pills, and combination pills, sometimes called COCs. Both pills have the same level of effectiveness, but you'll be protected from pregnancy after two days of starting mini pills, regardless of when you start. COCs work a little differently: You'll be protected as soon as you start taking the pill, as long as you take it within five days of the first day of your period.

Other things that can mess with your pills' effectiveness are some medications and supplements, according to Planned Parenthood, including antibiotics and antifungals (specifically Rifampin and Griseofulvin), along with certain HIV medications, anti-seizure medications, and St. John's Wort.

RELATED: 

Is there any way to make sure the pill is as effective as possible?

Don't freak: There are ways to maintain that 99 percent effectiveness rate—mainly, again, by taking your pills at the same time each day, says Dr. Greves. "That’s [the] recommendation. If you do not, that’s when it increases the risk for you of getting pregnant,” Dr. Greves says. It could be worth your while to set an alarm on your phone to go off at the same time everyday as a reminder. Or, if you usually go to sleep at the same time each night, think about designating bedtime as pill-taking time.

Even if you're stringent with your birth control, there's still that one percent chance you'll get pregnant—in which case, even more protection comes into play, says Dr. Greves. “If you are extra-nervous, [use] a condom with a birth control [pill],” she recommends. She adds that this can decrease your risk of contracting a sexually-transmitted infection from your partner, too, which oral contraceptives don't protect against. 

And if you're just really bad at remembering to take the pill, there are other birth control methods that might be better for you, says Dr. Greves. An intrauterine device (IUD), is a good choice, says Dr. Greves, since it has a much lower failure rate (0.004 percent, according to Dr. Greves) and can last up to 10 years, depending on the kind. The IUD “takes out the need for you to remember to take it,” Dr. Greves says. Other birth control options that are lower-maintenance include the Nexplanon, an implant that goes in your arm, and the NuvaRing, a small ring inserted into the vagina.

But if you love the birth control pill you’re on, making sure to take it at the same time each day and ensuring that your partner wears a condom during sex—that's truly the best way to try to avoid a pregnancy (aside from abstaining, of course). And just keep Milano's story in the back of your mind to remember that birth control pills aren’t perfect. Dr. Greves says, “Birth control serves multiple purposes, but in the setting of contraception—things can fail even with perfect use.”

To get more sexual health information delivered straight to your inbox, sign up for the Health Hookup newsletter