Royal status is a coveted thing. So coveted, that Indian jumping ants will shrink their brains and expand their ovaries just for a shot at the crown. 

Ant colonies are a family affair: Most of them have one queen, who is the only reproductive member of the clan, and the worker ants are her children. Queens usually can’t be replaced. But new research shows that, with the Indian jumping species, vast numbers of worker ants will go through intense physiological changes to redevelop the ability to reproduce and throw in their hat for the crown. Contenders shrink their own brains by as much as 25 percent, minimize their venom sacs, and expand their ovaries while increasing their oocytes (or eggs) seven-fold. The findings were published in the journal Proceedings of the Royal Society B.

These transformer ants are called “gamergates” (the “gam” rhymes with “ham”)—not to be confused with the 2014 internet campaign. In order to study their behavior and physiology, scientists identified two gamergates in each of 30 Indian jumping ant colonies reared in the lab. They left one gamergate ant as it was, and reverted the other back to worker status through solitary isolation. Researchers then added the reverted gamergates back to their colonies, observing and comparing behavioral and physiological changes between the pairs.

[Related: Why can some people smell ants? Here’s the answer to TikTok’s latest mystery.]

The study authors found that isolated gamergate ants were able to revert back to worker physiology in just six to eight weeks. In that time their brains, venom sacs, and ovaries re-morphed to match their worker peers. That reversibility is remarkable. While other species like honeybees can change the volume of their brains, the Indian jumping ant is the first insect species known to be able to take back those changes. It’s this ability that gives Indian jumping worker ants the chance to vie for royal status when a queen dies—and return to workers if they fail. 

The showdown for the crown is a dominance tournament that can last up to 40 days and involve up to half of a colony’s workforce. Out of this massive brawl emerge five to 10 pseudo-queens, gamergates who successfully dueled all the others with their antennae while undergoing their transformation. Eventually these winners develop pheromones to compel the colony to treat them like royalty, thus sealing their new status and allowing them to live the rest of their days as a group of ant baby-makers.

Becoming a gamergate likely requires brain shrinkage so that the ants can “divert additional resources to egg production, as brain tissue is metabolically expensive to maintain,” write the authors. Their venom sacs decrease as well, since taking out deadly threats to the colony are not usually on a queen’s agenda. On the flip side, when conceding the throne and reverting back to worker status, the brain and venom sacs need to expand again, since their functions are required to complete foraging tasks. 

[Related: Defend your house against ants—with science]

“It was pretty amazing to see that they were able to completely re-expand their brains to the exact same size that they were before,” Kennesaw State University biologist and study author Clint Penick told The New York Times. “This species shows an incredible amount of plasticity.”