For humans, decapitation is fatal. For a planarian flatworm, it’s a mild and temporary inconvenience.

These small animals are masters of regeneration. Cut off their heads, and a new one—sometimes two new ones—will regrow within a few days. Bisect them, and both halves will regenerate a full animal. Excise a small lump of tissue, and it too will produce a new worm. Transplant a single adult cell onto a dying planarian and the donor cell will take over, creating skin, nerves, muscle, and eventually an entire body. As one 19th-century naturalist wrote, planarians could “almost be called immortal under the edge of a knife.”

“The more you get to know about planarians, the more you fall in love with them,” says Akash Gulyani, who works with them at the National Center for Biological Sciences in Bangalore. Although most scientists who study planarians do so to understand how they regenerate so well, Gulyani had a different motivation. He wanted to know how these animals see the world—and how their senses recover as their eyes, brains, and heads regrow.

If you look at a planarian’s head, you’ll likely see two black dots. Those are its eyes, and they’re about as simple as true eyes can be. Each is a small cup lined with light-detecting cells. It can sense the presence and direction of light, but with no focusing lens, it only provides its owner with a blurry, low-resolution view of the world. And that view is processed by two clusters of neurons that can only loosely be called a brain. With this set-up, it seems likely that planarians are capable of only the simplest visual behaviors, like avoiding bright lights.

But when Gulyani started testing them, he found that planarians prefer certain colors. If given a choice between a blue space and a green one, they’ll almost always swim toward green. When choosing between green or red, they go for red. They could even distinguish between very subtly different shades of, say, blue or red. And that made no sense, because these animals shouldn’t have color vision at all.

Humans can tell colors apart because our eyes have three kinds of light-sensitive pigments, known as opsins. Each one responds to a different wavelength of light—red, blue, and green, respectively. By comparing and contrasting the responses of these pigments, we can work out what colors we are seeing. But planarians only have one kind of opsin. They shouldn’t be able to discriminate between blue and green, much less different shades of blue. And yet, “they always made a clear choice,” says Gulyani. “They were like little machines.”

Planarians choose a blue-green area over a blue one. (Shettigar et al. / Science Advances)

He thinks that the planarians aren’t really seeing color in the same way we do. Their single opsin responds most strongly to blue light, but it also responds weakly to other colors. The worm perceives these differences in terms of brightness, so blue looks brighter than green and green looks brighter than red—and it can then swim to whatever looks darkest. His student Nishan Shettigar confirmed this through clever experiments where he carefully adjusted the brightness of his differently colored lights. If he got the balance just right, the flatworms’ clear-cut preferences disappeared.

Creationists love to use the eye as evidence against evolution, claiming that these organs are so complex that they couldn’t possibly have arisen through gradual changes. What use, they say, is half an eye? But it’s clear that the complex eyes of humans, hawks, and octopuses evolved from simpler predecessors. Flat patches of light-sensitive cells gradually morph into planarian-style cups, which eventually gain focusing lenses.

Each step brings with it new abilities—like high resolution, or color vision—but it’s not like the intermediates are useless. As vision expert Dan-Eric Nilsson once told me: “Eyes didn’t evolve from poor to perfect. They evolved from performing a few simple tasks perfectly to performing many complex tasks excellently.” And the key to understanding the evolution of eyes is working out what their owners use them for.

That’s why planarians are so important. Their primitive eyes “would not be expected to display any other function than mere light detection,” says Alejandro Sánchez Alvarado from the Stowers Institute for Medical Research, “but I have seen land planarians hunting termites with great precision, as well as a myriad of other remarkable behaviors.” Gulyani’s study helps to explain why, he says: Clearly, these animals have eyes that are more sophisticated than anyone had believed.

The planarians don’t even need their eyes. When the team decapitated them, the creatures no longer reacted to visible light. But when the team shone ultraviolet light on them, the headless flatworms swam away. “The students were all freaked out,” Gulyani says.

A headless planarian swims away from ultraviolet light. (Shettigar et al., Science Advances)

Many animals, including flies, nematode worms, and cuttlefish, have networks of light-sensitive cells in their skin, outside of their eyes. They can effectively “see” with their skins (even though they can’t form any images). This ability is very useful for planarians because they can naturally reproduce by splitting themselves in two. A tail piece, devoid of eyes, would be vulnerable if it couldn’t find its way around. But thanks to its skin network, it can at least move away from bright sunlight.

As the creature’s eyes and brain regenerate, they also override the skin network. “At day five or six, there’s a very sharp switch where the signals from the brain become stronger, and it takes over,” says Gulyani.

It takes four days for a planarian to regrow its eyes. After day five, those eyes will have reconnected to the brain. At this point, the creature can swim away from light, but it can’t distinguish between subtle differences in color or brightness, in the way it normally could. That takes another week of regeneration.

It’s tempting to think that as these animals regenerate, they might replay some of the evolutionary events that gave rise to their modern bodies. As their heads re-grow, perhaps they’re fast-forwarding through the transition from distributed light-sensing skin to centralized eyes, and from simple light-avoidance to more complex color-sensing. That’s an idea Gulyani now wants to test. “We think there’s a lot of new biology to be uncovered,” he says.