Both vertebrates and invertebrates follow a general rule, known as Haller’s Rule, when it comes to brain and body size: “The brains of smaller animals are larger relative to body size than large-bodied forms.” Human brains are about 2 to 3 percent of our body mass, while the brains of some ants are 15 percent of their body mass. But the difference is even bigger when we talk spiders, according to a new study in Arthropod Structure & Development.

A group of researchers from the Smithsonian Tropical Research Institute and the University of Costa Rica measured (with great difficulty, I’m sure) the mass of the brains in adults of nine species of web-weaving spiders and in the young spiderlings of six of those species. The adults ranged in size from a tenth of a milligram to 2,000 milligrams (about .07 ounces).

“We discovered that the central nervous systems of the smallest spiders fill up almost 80 percent of their total body cavity, including about 25 percent of their legs,” says William Wcislo, a staff scientist at STRI in Panama. “The smaller the animal, the more it has to invest in its brain, which means even very tiny spiders are able to weave a web and perform other fairly complex behaviors.”

It seems that there are limits on how small a brain can be and still function properly. Brain cells cannot be smaller than the nucleus that contains all of the spider’s genes. Nerve fibers cannot get too thin or they wouldn’t be able to adequately carry and transfer a nerve signal.

As a result, the young spiderlings of the smallest spider species have bulging bodies to make room for all the necessary brain cells.