The biggest shark in our oceans already has a reputation for being a gentle giant, and it seems there's more to this than we ever realized. Whale sharks (Rhincodon typus) are filter feeders, thought to carefully comb the waters for tiny animals like krill.

Among the litany of tiny swimmers they scoop up are greens consisting of algae and other photosynthesizing organisms.

This can't be avoided, but researchers have wondered whether this vegetation is merely a garnish for the carnivore, or if it provides a side salad necessary to keep it swimming.

Researchers examining poop and skin samples identified what these 10-meter-long (32 feet) ocean hoovers are actually making use of from the giant pools of water they slurp through their systems.

"The poop did show that they were eating krill," says University of Tasmania biological oceanographer Patti Virtue. "But they're not metabolizing much of it."

Instead, whale sharks, which are true sharks with cartilage instead of bones, appear to be extracting nutrients from a heck of a lot of algae.

"This causes us to rethink everything we thought we knew about what whale sharks eat," says Australian Institute of Marine Science fish biologist Mark Meekan. "And, in fact, what they're doing out in the open ocean."

Meekan and colleagues' tissue analysis also revealed a fatty acid profile that was more consistent with omnivory than carnivory. They found skin rich in arachidonic acid (ARA), which is only present in large enough quantities to explain the levels found in whale sharks, in the floating macroalgae Sargassum.

In 2019, another study using tissue samples also found evidence that whale sharks are actually feeding off at least some organisms that are low on the food chain, such as plants and algae. What's more, they're not the only sharks that are omnivores: Bonnethead sharks (Sphyrna tiburo) eat significant seagrass.

These animals, also called shovelheads for obvious reasons, frequently swallow the plant materials as a consequence of hunting small prey like crabs, mollusks, and fish in dense seagrass habitats. So their need to cope with this plant material passing through their bodies is likely what eventuated in their ability to digest it.

The same may have happened to the whale sharks, the researchers suspect. In their evolutionary past, they may have originally been chugging down algae to digest the animals that live on it (epibionts), but now they can also digest and make use of the algae itself too.

"So, the vision we have of whale sharks coming to Ningaloo just to feast on these little krill is only half the story," explains Meekan. "They're actually out there eating a fair amount of algae too."

Unfortunately, to find enough of this floating organic matter, the whale sharks must follow oceanic features such as surface currents that gather these floating food sources together. These same features also aggregate pollutants in the ocean like plastic – so the whale sharks end up accidentally feasting on these too.

Meekan has observed some of this plastic passing through to the whale shark's poop. But it's likely to reduce their gut capacity, slow their digestion or cause them to regurgitate their food, the team notes in their paper. This could be harming these endangered animals who've experienced a 62 percent population decline over the past 75 years.

"On land, all the biggest animals have always been herbivores," says Meekan. "In the sea, we always thought the animals that have gotten really big, like whales and whale sharks, were feeding one step up the food chain on shrimp-like animals and small fishes.

"Turns out that maybe the system of evolution on land and in the water isn't that different after all."

This research was published in Ecology.