When French biologist Jean-Baptiste Lamarck set out to categorize the animal kingdom in 1801, he divided it into two groups: vertebrates, those with spines, and invertebrates, those without. The terms have stuck around for more than 200 years, but around 1900, scientists realized that they’d been categorizing wildlife wrong. Plenty of animals without spines—like starfish, invertebrates that extrude their own stomachs to eat—are more closely related to us than to their shellfish prey. Certainly, some animals have spines, and others don’t. But the spineless world is defined by much more than what it lacks. 

The real line that separates humans from insects, slugs, and shellfish? The answer lies partly in the anus. According to more recent thinking, the development of butts has become a key question for taxonomists cataloguing the diversity and evolution of the animal kingdom.

All animals begin life as a rapidly dividing bundle of cells. Early in that process, the embryo is just a tiny sphere of cells. But to develop a gut, the round blob needs to somehow turn itself into a donut. To do so, a dimple forms on the sphere, and eventually pushes its way to the opposite wall. In humans and starfish, that dimple becomes the anus, working its way back to a second opening—what becomes the mouth. In shellfish or crabs, these openings develop in reverse; the original dimple usually becomes the mouth.

That distinction separates most animals into two categories: deuterostomes, or “mouth second,” and protostomes, or “mouth first.” While all vertebrates are butt-first, not all invertebrates fit into either bucket. Even the textbook Invertebrates: A Synthesis distances itself from the word “invertebrate,” writing on the first page, “The distinction [between vertebrate and invertebrate] is hardly natural or even very sharp.” So-called invertebrates aren’t categorized by their lack of spine, so much as their approach to the anus. 

[Related: Watch beetles shoot hot chemicals from their butts to escape toad bellies]

Or so it used to be. “It is true that deuterostomes were classically said to be defined by the development of the anus,” says Imran Rahman, a paleontologist at London’s Natural History Museum, “but we now know that some protostomes also develop in the same way.”

More recently, researchers realized that certain mouth-first animals, like some species of brachiopods, a type of shellfish, developed butt-first. Others develop both at the same time, where the spherical embryo hollows out and rolls over on itself like a burrito. In 2016, a team demonstrated that the shape of the gut is actually an artifact of a more subtle process: The embryo transforms from a sphere into a stretched out, shrimp-like shape.

That would mean that our common ancestor may have evolved the shrimp-like physique first, and then figured out how to build its guts. The findings, the researchers argued, suggest that anuses (or in some cases, mouths) have evolved over and over again.

That could explain the case of the comb jellyfish, which branched off long before the ancestors of starfish and humans had evolved a waste disposal system. Most jellies have what are called “blind guts”—an entrance with no exit. Most gulp down food, digest it, then spit up the remains.

But in 2016, an evolutionary biologist recorded footage of translucent comb jellyfish eating tiny, glowing plankton. As the animal digested, the video captured the food moving through the jellies’ bodies, and then, after a few hours, out a pair of pores on the back of their “heads.” (When the biologist played the video at a conference, the audience reportedly gasped out loud.) This ability had gone undiscovered for more than a century because the jellyfish have what researchers describe as a “transient anus”—a temporary booty that only appears when the animals really have to go.

It’s possible that the anus is much older than scientists realize, and comb jellies are evidence of a common ancestor with a through-gut. But it’s also plausible that the butt is just so valuable that jellyfish have come up with it on their own.

And indeed, the oldest purported ancestor of humans, starfish, and all so-called “mouth second” animals is, intestinally speaking, a lot like a jellyfish. The creature was a seafloor-dwelling animal, called Saccorhytus coronarious, or “crowned wrinkly bag.” It was about the size of a pinhead, and had a huge, gaping mouth on top of a round body. It had no anus, but was covered in pores that its discoverers believe to be a precursor to gill slits. “However, not everyone is convinced by this interpretation,” says Rahman.

The name deuterostomes has stuck around, though. More recent genomic work has demonstrated that we still evolved alongside animals that basically share our intestinal toolkit, letting us know that the animal kingdom is defined as much by butts as by spines.