Great white sharks are often thought of as the most fearsome predators in the ocean.

But even these sharks are afraid of something. A new study found that when great whites have encountered killer whales, or orcas, near their hunting grounds, they've fled and stayed away.

In 2017, there were three reports of orcas killing great white sharks off the coast of South Africa and eating their livers.

Who's afraid of the big, bad ... whale?

The lovable orca of "Free Willy" fame, also called a killer whale or blackfish, is a stone-cold predator. So much so, in fact, that it can send the world's most feared shark into hiding.

A new study published in the journal Scientific Reports found that the mere presence of orcas in the water led to a noticeable absence of great white sharks.

The researchers behind the study monitored the waters in the Pacific Ocean off the Farallon Islands near San Francisco, where great whites are known to hunt for elephant seals. They found that if a pod of orcas came along, the sharks fled their preferred hunting grounds and didn't come back until the following year.

Three male orcas hunt together near Kaldfjord, in Norway. Getty Images

"It's a bit ironic — when we think about white sharks, it's hard to imagine they are risk-averse," Salvador Jorgensen, a shark expert at the Monterey Bay Aquarium and the lead author of the study, told Business Insider. "But this study shows that even for these massive predators, knowing when to pull out and flee is an important part of their repertoire."

When confronted with orcas, sharks hightail it

Between September and December each year, great white sharks congregate in California's Greater Farallones National Marine Sanctuary, off the coast of San Francisco, to dine on young elephant seals.

To keep tabs on these sharks' movements, Jorgensen and his colleagues attached tracker tags to 165 great white sharks from 2006 to 2013.

The researchers then compiled population data and field observations from the area from 1987 to 2013 so they could cross-reference how the behavior of elephant seals, sea lions, and orcas might have affected shark movements over time.

According to their data, orcas — who also enjoy a dinner of elephant seal — showed up in the area only rarely during hunting season, seen on just 18 days of the entire 27 years of observations. Sometimes the orcas were around for less than an hour.

But that was more than enough for the sharks. During those 18 days, the study's authors found, there were four observed encounters between orcas and great whites. Data from the sharks' tracker tags showed that when these two predators found themselves in the same area, all the great whites swam away within minutes of the orcas' arrival.

Then the sharks didn't return until the next hunting season.

Based on other observations of interactions between whales and sharks in California's waters, it seems that great whites have good reason to flee.

The livers of great white sharks are an orca delicacy

In 1997, whale watchers near the Farallon Islands observed an orca attacking and killing a great white shark. Then in 2016, a drone captured footage of a great white being ripped apart by an orca in Monterey Bay.

A colony of elephant seals resting off the California shore. Fabian Krause /EyeEm/Getty

Orcas have killed great white sharks in other parts of the world too, Jorgensen said.

"Recent reports from South Africa and Australia suggest that the relationship between these two ocean giants may have a long legacy, perhaps spanning millennia," he said.

The most notable clash of these marine titans came two years ago in South Africa, when researchers found three great white sharks washed up on the shores of Kleinbaai. The sharks' livers were missing, as was one shark's heart.

Scientists determined that all three had run afoul of orcas, which dined on their nutrient-rich livers. The authors of the new study suggested that eating great whites' highly caloric livers could give orcas an energy boost.

An orca pod encircles a group of seals trapped on an ice floe. Tobias Brehm/Shutterstock

Ultimately, the authors aren't sure whether the orcas passing by the Farallon Islands are targeting great white sharks for their internal organs, or whether the whales are just bullying their competition out of the prime spot at the elephant seal drive-thru.

Orcas are bigger, badder, and better hunters

Great white sharks can grow to be 20 feet long and weigh 4 tons. They can swim up to about 35 mph and use their superior sense of smell to home in on prey from up to two miles away.

Read more: An 18-foot great white shark ate a dead whale in front of a boat full of tourists

Great whites can breach up to 10 feet to snag prey. Shutterstock

The sharks' mouths hold 300 serrated, perpetually self-replacing teeth. When hunting, they like to position themselves below unsuspecting prey in the water, then rocket toward the surface and chomp down. Great whites can leap up to 10 feet out of the water, breaching like a whale, before sinking below the waves with their catch.

That all sounds scary — until you compare it with orcas.

Orcas swim just as fast as great whites. But they're bigger, reaching lengths of 32 feet and weighing up to 6 tons. The whales also hunt cooperatively, in pods of up to 40, herding and encircling prey, then using their 4-inch teeth to chomp on other whales, otters, seals, and penguins.

According to SeaWorld, orcas prey on more than 140 species of animals around the world, including land-based critters, like moose.

Orcas are even known to purposefully beach themselves on icebergs or sandbars to frighten seals and penguins into the water, then track them down and swallow them whole.

An orca hunting sea lion pups on a beach at Punta Norte, in Argentina. AP Photo/Daniel Feldman

As it turns out, the outcome of the predator face-off near the Farallon Islands favored the elephant seals.

The researchers said that while sharks hunted about 40 elephant seals in the area each hunting season, those hunts stopped as soon as orcas arrived on the scene. So during the years that the great whites left prematurely, elephant seals were attacked and eaten much less often, they said.