In 1987, Justin Schmidt, a biologist at the Southwestern Biological Institute, found himself up a tree in Costa Rica. Shimmying over a branch that extended precariously over a cliff, he was trying to get closer to a black wasp nest hanging in the limbs of the tree to collect a few specimens for research. 

He was being careful, and had come geared up with a bee veil to prevent the flying insects from stinging his face. But the wasps were more determined than he was prepared. They hovered as close as they could, and then, instead of stinging, squirted venom directly into his eyes.

The burning sensation and the pain were immediate. Unable to see, Justin screamed for help as he slid down the tree with two legs wrapped around the trunk, and a bag of wasps hanging from one of his hands.

“That was an adventure,” he laughs now. 

Getting stung by insects—often extraordinarily painful ones—is an occupational hazard for the author of The Sting of the Wild. He’s experienced everything, from the comparatively manageable burning pain of the paper wasp, to the blinding electric shock of the tarantula hawk wasp

[Related: He’s let thousands of insects bite and sting him—here’s what he’s learned]

All of this has taught him how much a sting can hurt, but most importantly, how to avoid them. Should you run into these insects in the wild, Schmidt’s lessons can come in handy—starting with never disturbing a wasp nest. 

Bees, wasps, and hornets, oh my!

Ninety to 100 people die yearly from allergic reactions resulting from bee, hornet, and wasp stings. This is also the most common potentially fatal animal encounter in the outdoors.

However, not all stinging insects are created equal. Hornets are a type of wasp that tends to be more aggressive than bees and produce more painful stings. To make matters worse, wasps and some bees don’t lose their stingers after they jab you, so they can do so repeatedly. Other types of bees, on the other hand, are one and done. 

But no matter if it’s once or multiple times, what happens in your body when one of these insects attacks you is pretty similar. Through the sting, bees or wasps envenomate you by injecting specific toxins and enzymes.

Your body registers the intrusion almost right away. White blood cells race to the rescue and mast cells (a type of white blood cell) release histamines. These compounds play a key role in your body’s response and can cause swelling. As the venom spreads, it breaks down the membrane of any cell it touches. This can activate your immune system, which ultimately creates antibodies against the venom.

[Related: The US is running out of wasp venom. That’s bad.]

This is when those who experience highly allergic responses to bee or wasp stings (only 5 percent of the population) should resort to an epinephrine autoinjector (like an EpiPen) and immediate medical attention to prevent anaphylaxis. The rest will only feel throbbing pain, irritation, swelling, and itching. 

It’s certainly not pleasant, but without an overly sensitive reaction, most adults can handle up to 10 stings per pound of bodyweight without major consequences. Any more than that and the venom can cause your kidneys to struggle and clog as they try to rid your body of damaged cell tissue.

The amount of venom an insect injects determines how painful a sting is, and it can vary depending on the species. But whether you run into a bee or a wasp, you’re probably better off with no sting at all.

How to avoid a sting

The easiest and most effective way of avoiding stings is keeping your distance from nests, colonies, and swarms. If you happen to stumble upon one, walk swiftly and calmly in the opposite direction. This will prevent you from further riling up the insects. You should also make your exit in a straight line, as running in zig-zag will just keep you in the danger zone for longer, Schmidt says.

If a swarm attacks you, run as fast as you can away from it, and preferably toward people who may be able to help. By removing yourself from the immediate vicinity, you may be able to prove to the insects that you’re not a threat and they’re more likely to leave you alone.

However, if you are dealing with one or two stinging insects buzzing around your head, don’t freak out. Chances are, the bee, wasp, or hornet is just investigating to assess the threat. If you swat at it or violently jerk from side to side, you may be indicating you’re trouble, and encouraging the insect to sting. 

Hiding in plain sight is also a good idea. For this, Schmidt recommends you keep still and hold your breath. 

“Breath is what tells them you’re there,” he says. 

Because most insects get cues from smells in the air, when you hold your breath for 10, 30, or even 50 seconds, they will no longer detect your presence. This will very likely result in bees and wasps leaving you in peace.

Next, when it comes to your outdoors wardrobe, choose light colors, and ditch hues like purple, violet, and blue, as bees are especially attracted to them. Contrary to what you might think, floral prints are also ok, as fabrics don’t have those ultraviolet colors in real flowers bees love so much.

[Related: Bees deal with darkness the same way humans do]

Another myth is that perfumes or scented sunscreens can entice bees, wasps, and hornets. This is not true. Lemon may be an exception, though. The citrusy smell resembles a bee pheromone, which might make you particularly attractive to these insects if you wear it on a hike.  

What to do if you get stung

If they haven’t already, chances are a bee or wasp will sting you at some point in your life. When they do, don’t panic. 

Start by moving away from the area where it happened in case there are more insects nearby. If the culprit is a bee, remove the stinger by scraping your fingernail over the sting to dislodge it. Studies show that leaving the stinger in for as little as eight seconds can increase swelling by 30 percent, so act quickly. 

If you experience abnormal swelling or shortness of breath, you may be having an acute allergic reaction. In that case, your first and most important priority is to seek medical attention immediately and as fast as you can.

[Related: What You Need To Know About The EpiPen]

On the other hand, if everything looks normal, then your next step will be to focus on recovery. First, wash the sting with soap and water to avoid infection. If it itches, use a topical steroid or oral antihistamine. Follow up by applying a cold compress on the affected area to reduce swelling and pain.

Should you not have access to any medication, Schmidt recommends making a paste with a small amount of table salt and water (or another liquid), and put it directly on the sting site to relieve pain.

“We don’t know why, but it does seem to work,” Schmidt suggests. You should also avoid applying heat, ammonia, and vinegar to the site, he adds, as they are useless at best, and can make pain more acute at worst.

Finally, if you have a history of severe allergic reactions, remember to always carry auto-injectable epinephrine with you, no matter if you’re in an urban area or in the middle of the backcountry. If a bee or wasp stings you and you have to inject yourself, make sure to visit a nearby emergency room right away.

Correction May 25, 2021: An earlier version of this story said that all bees can only sting once, but some can sting multiple times.
Correction May 25, 2021: An earlier version of this story suggested human cells have cell walls, but they do not—they have cell membranes.