In September 2014, a 6-year-old boy was walking just 10 feet ahead of his parents on a trail in the hills of Cupertino, California, when he was attacked by a mountain lion.

Horrified, his family raced to his aid as the lion mauled him and dragged him into the bushes. His parents fought the cat off, but the mountain lion followed them all the way to the trailhead before they got their injured son to safety.

Like many predators, mountain lions are making a comeback. Today, mountain lions are found in Florida and throughout much of the American West, even creeping into suburban neighborhoods and parks — “pretty much wherever there are deer,” says California wildlife scientist Steve Torres.

And as the mountain lion population increases, so have the number of attacks. Although only 300 attacks have been recorded in the United States, they have risen sharply since the 1980s. But if such reports make you consider calling off your next hike in the hills, remember that the likelihood of an attack is vanishingly small.

Despite their size and power, mountain lions rarely attack humans. Bear attacks are much more common. “The reality is that these [assaults] are so rare that in general mountain lions are nothing to be fearful of,” says Texas wildlife biologist Raymond Skiles.

Related: What To Do If You Encounter a Bear

Why not? Mountain lions — also called cougars or panthers — tend to avoid people. Even though cougars measure up to 8 feet from their nose to the tip of their ropy tails, you may have even passed right by one without realizing it. Torres recalls talking to one of the first biologists to radio-collar mountain lions, allowing scientists for the first time to track the elusive cats’ movements. “They were so close to people,” the scientist exclaimed. “Lions are sleeping next to bike paths. They’re all over the place. It’s amazing they’re so rarely seen.”

Still, it doesn’t hurt to be prepared, just in case you ever do run into the rare big cat who gets aggressive.

Staying safe in lion country

So what should you do while hiking or camping in mountain lion territory? Follow these tips, compiled by the National Park Service.

Safety in numbers. If you are concerned about an attack, don’t walk or cycle alone. Solitary hikers are three times more likely to be attacked than people in a group. Says Torres, a wildlife investigator for California Fish and Game who has written a book on mountain lions: “I can’t think of any lion attacks that have resulted in a fatality when there were two adults.”

Keep children close. Never let kids run ahead of you or fall behind on the trail.

Related: Safer Winter Hiking

Make yourself look big. Stay calm, face the lion and raise your arms to look as large as possible.

Give it a chance to leave. Never approach a lion that isn’t threatening you. Most big cats are calm and try to avoid confrontation. Back up slowly and be sure to give it a way to escape.

Don’t run away, which may trigger an attack from behind. Scoop up young children so they don’t panic and run.

If approached, get aggressive. Mountain lion attacks sometimes occur by ambush. But often the cat is seen and decides to stalk toward its intended prey (i.e., you). Try to look threatening — wave your arms, shout, scream. Says Skiles, a wildlife biologist at Big Bend National Park in Texas, “They’re easy to intimidate. You want to be the bad one on the block when it comes to showing them you’re not prey.”

Throw sticks and stones. If bluster doesn’t scare off the approaching cat, throw stones, sticks, whatever is at hand. Research has shown that assertive behavior on the part would-be victim — yelling, throwing objects, holding up your arms to appear bigger — can ward off an attack. “We’re so attuned to being passive and deferential to wildlife it’s sometimes hard to get that message across to people here in the park,” says Skiles. “We do need to demonstrate who’s in charge out here, and we’re the top of the food chain.”

Fight back. If the lion attacks, fight back with anything you can get your hands on. Skiles tells the story of a man attacked at Big Bend National Park: The cougar had him on the ground and was biting his leg. But the man managed to grab a rock and bash the cat in the head. “That did the trick,” says Skiles. “You need to stand your ground. You need to run it off. You need to use the instruments at your disposal.”

Related: “Survivorman” Les Stroud: How to Survive Being Lost in the Wild

Do not — repeat — do not play dead. The worst outcomes occur when human victims do nothing, according to wildlife researchers. Unlike bears, who may attack people when they feel threatened, cougars pounce when they’re hungry. “You don't want to play dead as you might with a grizzly bear. Because these animals [mountain lions] are predators that have decided to see you as food,” says Skiles.

Report it. Afterwards, tell the police, park service, and fish and game about the incident immediately. This may save other people the trauma of a similar encounter.

Doing battle with a 150-pound ball of sharp claws and teeth is something none of us ever hope to do, but if a cougar attacks, you really have no choice. By fighting back, even some children and grandparents have lived to tell the tale.

In California, Nell and Jim Hamm were hiking in Prairie Creek Redwoods State Park in 2009 when a mountain lion ambushed and began mauling 70-year-old Jim. Hearing her husband’s cry for help, Nell, 65, managed to fend off the cougar by beating it for several minutes with a heavy tree branch. Her husband — whose head was clamped in the cougar’s jaws — coached her from the ground. The beast finally let go and leaped back when she clubbed it on the nose, then vanished after she held up the stick and screamed at the top of her lungs. "You hear remarks of hero," she told reporters afterwards. "It wasn't that. We love each other very much … and we just fought together like we do everything."

Greg Breining is a Minnesota-based journalist who writes about science, travel and nature for national and regional magazines, including Audubon and National Geographic Traveler. His books about the natural world include Wild Shore and Paddle North.