It's easier for you to get a cold than it is to get HIV, the virus that causes AIDS. HIV is only spread through specific body fluids: blood, semen, pre-seminal fluid (pre-cum), vaginal and rectal fluid, and breast milk. So you can prevent an infection by avoiding those.
The most common way people get HIV is by having sex with an infected person. You can't tell by looking at someone whether they have HIV, so you have to protect yourself -- and your sex partner.
You can lower your risk a lot by using a latex or polyurethane condom when you have sex. (Natural-skin condoms prevent pregnancy, but they don't prevent infections.) Put the condom on as soon as there's an erection. Use water-based lubricants, no oils.
A female condom, called a vaginal pouch, also protects against HIV.
Oral sex without a condom or dental dam isn't safe, but it's far less risky than unprotected vaginal or anal sex.
Don't have unprotected sex outside marriage or a committed, exclusive relationship.
Safer Drug Use
The safest thing is to not use drugs, especially injected ones. But if you're not ready to or can't stop, you can still lower your chances of getting HIV.
If you use drugs, don't inject them.
If you inject drugs, don't share the equipment. This includes everything: needles, syringes, cookers, cotton, and rinse water. Find out if there's a needle exchange program near you, where you can trade in used ones for new, clean ones.
Don't have sex when you're high or drunk. It's easy to forget or not care about safe sex.
When Someone Is Bleeding
Be careful and avoid blood getting into any cuts or open sores on your own skin, or in your eyes or mouth. Wear gloves and protective eyewear if you can. Although it's rare, you can be infected by HIV from contact with the blood of an infected person.
If You're at High Risk
People who are very likely to get HIV -- like sex workers, or those in a relationship with someone who is HIV-positive -- can take a pill every day to help prevent an infection. This is called PrEP, or pre-exposure prophylaxis.
But it's not a free pass. You'll still need to try to prevent contact with the virus.
If There's a Chance You've Been Infected
Call your doctor or go to an urgent care clinic right away. You might be able to take medicine to stop the infection. You need to start within 72 hours, and sooner is better for it to work.
It's not like a morning-after pill. The treatment lasts for several weeks, and there can be serious side effects. But it could keep you from getting HIV.