How to Avoid STDs: Condoms, Vaccines, and More

The most effective way to avoid STDs (also called STIs) is to use a combination of strategies rather than relying on any single one. Condoms, vaccines, regular testing, and honest conversations with partners each reduce your risk, and together they provide strong, layered protection. Here’s how each strategy works and what it actually looks like in practice.

Condoms: What They Protect Against (and What They Don’t)

Male latex condoms provide more than 90% protection against HIV, hepatitis B, and gonorrhea when used correctly. Protection against chlamydia and syphilis is lower, in the range of 50 to 90%, because these infections can sometimes be present in areas the condom doesn’t cover. For infections spread primarily through skin-to-skin contact, like herpes and HPV, condoms reduce risk but can’t eliminate it since the virus can live on surrounding skin.

How you use a condom matters as much as whether you use one. One study found that touching the tip of the penis with hands before putting on the condom was strongly associated with exposure to semen, increasing the odds by roughly six times. That means washing your hands and avoiding contact with the tip before rolling the condom on is a simple step that makes a real difference. Other common mistakes include not leaving space at the tip, using oil-based lubricants with latex (which weakens it), and waiting too long to put it on. Use a new condom for every act of sex, including oral sex, and put it on before any genital contact.

Internal (female) condoms and dental dams offer additional barrier options for vaginal sex and oral sex, respectively. If you have a latex allergy, polyurethane and nitrile condoms provide similar protection.

Vaccines That Prevent STIs

Two STIs are directly preventable with vaccines: HPV and hepatitis B.

The HPV vaccine is routinely recommended for everyone through age 26 and requires two or three doses depending on the age you start. If you’re between 27 and 45, you can still get vaccinated through a shared decision with your doctor. HPV causes genital warts and is the primary driver of cervical, throat, and anal cancers, so this vaccine does more than prevent an infection. It prevents cancer.

The hepatitis B vaccine is part of the standard childhood schedule, but many adults missed it or never completed the full series. If you’re unsure whether you were vaccinated, a simple blood test can check your immunity. Hepatitis B spreads through sexual contact and blood, and chronic infection can lead to serious liver disease.

PrEP and Post-Exposure Prevention

If HIV prevention is a specific concern for you, PrEP (pre-exposure prophylaxis) is a medication you take on an ongoing basis that reduces the risk of getting HIV from sex by about 99% when taken as prescribed. It’s available as a daily pill or as an injection given every two months. PrEP is most commonly prescribed to people whose partners are HIV-positive, people with multiple sexual partners, and people who don’t consistently use condoms.

A newer option targets bacterial STIs rather than HIV. In 2024, the CDC released guidelines for doxycycline post-exposure prophylaxis, sometimes called doxy-PEP. This involves taking a single 200 mg dose of an antibiotic as soon as possible after sex, and no later than 72 hours afterward. It’s been shown to significantly reduce rates of chlamydia, syphilis, and gonorrhea. The guidelines currently recommend it for men who have sex with men and transgender women who have had a bacterial STI in the past year. You’d need a prescription and an ongoing conversation with your provider about whether it fits your situation.

Get Tested on a Schedule

Many STIs cause no symptoms at all, especially in the early stages. Chlamydia and gonorrhea frequently go unnoticed, and someone can carry and transmit HIV or syphilis for weeks or months without knowing. Routine screening is the only way to catch these infections before they cause damage or spread to partners.

The U.S. Preventive Services Task Force recommends that all sexually active women 24 and younger be screened for chlamydia and gonorrhea. Women 25 and older should continue screening if they have risk factors like a new partner, more than one partner, a partner who has other partners, inconsistent condom use, or a history of STIs. For men, there’s no blanket screening recommendation, but men who have sex with men are generally advised to screen at least annually for HIV, syphilis, chlamydia, and gonorrhea.

Timing matters when you get tested. After a potential exposure, syphilis takes two to six weeks to show up on a test, and HIV takes three to four weeks. If you test too early, you can get a false negative. A good rule of thumb: if you’re tested for gonorrhea or chlamydia shortly after a new encounter, follow up with HIV and syphilis testing about six weeks later to make sure nothing was missed.

Fewer Partners, Lower Risk

The math here is straightforward: the more sexual partners you have, the greater the chance of encountering an STI. Mutual monogamy, where both you and your partner are exclusively having sex with each other and have both tested negative, is one of the most effective risk-reduction strategies outside of abstinence. The key word is “mutual.” It only works if both partners are truly monogamous, which is why testing and honest communication are essential even in committed relationships.

Serial monogamy, meaning a pattern of exclusive relationships one after another, still carries risk because each new partner is a new exposure. Getting tested between partners, ideally with enough time for window periods to pass, closes that gap.

How to Talk About It With a Partner

The conversation about sexual health is one most people dread, but it’s one of the most effective prevention tools you have. The CDC’s guidance is simple: talk before you have sex, not after. You don’t need a script. You need a few direct questions. When were you last tested? What were you tested for? Have you had any new partners since then?

Being upfront about your own status sets the tone. If you have an STI, even one you’re being treated for, let your partner know. If you suggest getting tested together, it removes the implication that you’re singling them out. Most people respond well to honesty when it’s delivered without judgment. And if someone reacts badly to a reasonable request about testing, that’s useful information about whether you want to be sleeping with them in the first place.

Layering Protection Works Best

No single method covers everything. Condoms are excellent against HIV and gonorrhea but only partial against herpes and HPV. The HPV vaccine handles what condoms miss for that virus. PrEP covers HIV but nothing else. Testing catches what slips through all of those defenses. The strongest approach combines several layers: consistent condom use, vaccination, testing between partners or at regular intervals, and open conversations about status. Each layer catches what the others might miss, and together they bring your risk close to zero for most infections.