Some squids and octopuses have taken a page from Harry Potter.
A new study from Duke University has found that two cephalopods, the octopus Japetella heathi and the squid Onychoteuthis banksii, have the ability to quickly switch between transparency and pigmentation to essentially become invisible, a trait that helps the animals avoid detection by predators.
WATCH THE CEPHALOPODS CHANGE COLOR IN THE VIDEO BELOW
Both animals live between 600 and 1,000 meters (1,970 to 3,280 feet) below the ocean's surface, in what's called the lower Mesopelagic zone.
According to the release from Duke, both this squid and octopus are transparent in their resting state. Discover Magazine reports that predators like the hatchetfish that have upward-facing eyes have a difficult time seeing them because the little bit of light at this depth passes through their transparent bodies.
But this only helps the cephalopods hide from some of the predators.
"The problem is that when you get to that depth, a lot of animals are essentially running around with flashlights," Sönke Johnsen, the co-author of the study, told HuffPost.
So when a predator with its own "flashlight" -- like the headlight fish -- shines its bluish light at either one of these cephalopods, the pigments instantly become red, allowing the animals to camouflage.
"These guys are clever enough to know what might be looking for them," said Johnsen. "They sort of get the best of both worlds."
"Cephalopods in general are just remarkable animals for how clever they are for adapting to different circumstances," Johnsen added.
WATCH: Deep Water Camouflage:
Want more awesome ocean animals? Check out the slideshow below for some of our favorite shark photos:
The Morning Email helps you start your workday with everything you need to know: breaking news, entertainment and a dash of fun. Learn more