Between the ages of six and eight or so, when I was old enough to run around outside but too young to have cooler things to do, I spent quite a bit of time with insects. Not that I was especially into entomology or even science. Bugs were just something fun and animate to play with: I kept caterpillars, feeding them fresh leaves and cleaning their jars every few days, nourishing them to moth-hood. At the same time, with no sense of contradiction, I spent entire summer vacation mornings killing ants, spraying them with window cleaner, setting them on fire, or coaxing them to fight in bottles.

If that sounds sadistic, let me say that it wasn’t done with a cruel spirit, or any memorable pleasure at the ants’ discomfort. It was just something to do, and I don’t think my experience was especially unusual, at least not among boys of my generation. Quite a few guys I’ve known can relate similar stories. Magnifying glasses are a fairly universal feature.

These days I don’t much like to think of those ant-massacring mornings, but I did after reading about Backyard Brains, a Kickstarter-funded neuroscience education company. The company’s flagship product is RoboRoach, a $99.99 bundle of Bluetooth signal-processing microelectronics that’s glued to the back of a living cockroach and wired into the stumps of its cut-off antennae. Cockroaches use their antennae to detect objects; they react to electrical pulses sent through these nerves as though they have bumped into something, allowing children to remote‑control them with smartphones. Other experiments involve measuring nerve activity in severed roach legs.

Given that few people spare a second thought to kitchen cockroach-stomping or classroom ant farms, the experiments might not seem too troubling. But using the insects like this, rather than killing them or watching them, is a different proposition. Some bioethicists have criticised Backyard Brains for encouraging children to think of living beings as tools, existing not for themselves but for our entertainment and edification. Those misgivings resonated with me. High-school students might do this in biology classes — but children, on the low end of the company’s suggested age‑appropriateness?

One of childhood’s elemental lessons, learnt in no small part through our immediate relationships with creatures less powerful than us, is how to think about and treat other living beings. There’s no bright line, at least not then, between empathising with animals and with people. I’m thankful that, in the end, my caterpillar-caring side prevailed over my ant-frying tendencies, and wonder if the instructive virtue of empathising with insects might outweigh whatever educational gains can be had from steering them with an iPhone.

A note on the company’s website does reassure customers that, though it’s unknown if insects feel pain, anaesthesia is used during procedures on cockroaches, and also on earthworms and grasshoppers involved in other experiments. This question of pain is an interesting one, and it opens up its own can of worms: as philosophers and scientists usually define the term, pain is intertwined with emotion, which in turn is intertwined with consciousness. You can’t experience pain unless there’s a you — a sense of self, an interior dialogue beyond the interplay of stimulus and involuntary response, elevating mechanics to consciousness.

Such sentience is quite unlikely in a bug, says Backyard Brains, and most people would likely agree. ‘It’s very important to avoid anthropomorphising the cockroach with thoughts such as: “If I do not want my own leg cut off, then the cockroach does not want its leg cut off”,’ reads the site. And yet — do we really know this? A good scientist assumes nothing, and the possibility of insect sentience is rather more scientifically complicated than one might expect. In fact, there’s good reason to think that cockroaches just might possess it.

Before dismissing bug consciousness out of hand — their brains are so tiny! And, they’re bugs! — it’s worth recalling that one of the first scientists to seriously consider the notion was Charles Darwin, who spent most of his adult life, even as he completed The Descent of Man (1871) and On the Origin of Species (1859), thinking about earthworms.

Earthworms aren’t insects, of course, but for all practical purposes people usually lump them together in the realm of invertebrate-creepy-crawlies-with-no-meaningful-inner-life-to-speak-of. Not so Darwin. His investigations of ‘how far [the worms] acted consciously’, as described in his final book, The Formation of Vegetable Mould Through the Action of Worms, with Observations on Their Habits (1881), run for more than 30 pages. In painstaking detail, he describes how earthworms plug the entrance to their burrows with precisely chosen and arranged leaf fragments, and how instinct alone doesn’t plausibly explain that.

‘One alternative alone is left, namely, that worms, although standing low in the scale of organisation, possess some degree of intelligence,’ wrote Darwin. ‘This will strike everyone as very improbable; but it may be doubted whether we know enough about the nervous system of the lower animals to justify our natural distrust of such a conclusion.’ Moreover, as the environmental philosopher Eileen Crist writes in her essay ‘The Inner Life of Earthworms’ in the edited collection The Cognitive Animal (2002), Darwin doesn’t simply describe the worms as unexpectedly sophisticated problem-solving machines. His descriptions implicitly acknowledge the realm of experience, of lives not lived by instinct alone, but with awareness and some ability to make decisions.

The worms couldn’t speak, but the weight of evidence did

Some might accuse Darwin of anthropomorphising, or carelessly attributing human qualities to other animals. But assuming human uniqueness can be its own fallacy, too. Darwin was, simply, scientifically open-minded. He granted that earthworms might be conscious of what mattered to them — objects in their immediate environment, the shape and temperature of their burrows — and made inferences on the basis of their behaviour and what’s known of intelligence in other animals, including humans. The worms couldn’t speak, but the weight of evidence did.

That principle is fundamental to the consciousness many scientists now acknowledge in mammals and birds (and, depending on whom you talk to, in reptiles, amphibians and fish). As for cockroaches, intimations of their experience could come from research on honeybee cognition, which has fascinated researchers ever since the zoologist Karl von Frisch’s 1973 Nobel Prize-winning discovery of waggle dances, the complicated sequence of gestures by which honeybees convey the location and quality of food to hive-mates.

Using methods designed to probe building-block fundaments of thought — can a bee learn to follow green rather than red marks through a maze? How quickly does it apply that concept to geometrical marks, rather than colour? Do waggle dances convey only spatial information, or olfactory qualities, too? How does a bee adapt when moved to an unfamiliar location or exposed to a new stimulus? Does that correlate with past experience? — scientists have assembled a portrait of extraordinary cognitive richness, so rich that honeybees now serve as model organisms for understanding the neurobiology of basic cognition.

Honeybees have a sense of time and of space; they have both short- and long-term memories. These memories combine sight and smell, and are available to bees independent of their immediate environments. In other words, they have internal representations of their worlds. They can learn to recognise patterns, and also concepts: above and below, same or different. They have simple emotions and beliefs, and apply those memories and concepts to their decisions. They likely recognise individuals. Those are qualities typically ascribed only to larger animals, with far larger brains, but life’s challenges are universal: find food, don’t become food, reproduce.

In a chapter of Evolution of Nervous Systems in Invertebrates (2007), the neuroscientists Randolf Menzel, Björn Brembs and Martin Giurfa argue that, even if we’ve tended to assume that insects solve life’s challenges mechanistically and without thought, there’s now ‘considerable evidence against such an understanding’. Cognition is only one facet of mental activity, and not a stand-in for rich inner experience, but underlying honeybee cognition is small but sophisticated brain, with structures that effectively perform similar functions as the mammalian cortex and thalamus — systems considered fundamental to human consciousness.

The upshot of all this, thinks Menzel, is that bees themselves possess some form of consciousness. It’s not a human consciousness, obviously, but certain features are likely to be common: a sense of awareness and intent, an ‘inner doing’. And if it sounds like maybe someone’s spent too much time with bees, it’s also the belief of Christof Koch, the chief scientific officer at the Allen Institute for Brain Science in Seattle and one of the world’s foremost investigators into the neural basis of consciousness. To Koch, consciousness is a function of neurological complexity, which bees and many other insects clearly have in abundance.

The nature of their consciousness is difficult to ascertain, but we can at least imagine that it feels like something to be a bee or a cockroach or a cricket. That something is intertwined with their life histories, modes of perception, and neurological organisation. For insects, says Koch, this precludes the reflective aspects of self-awareness: they don’t ponder. Rather, like a human climber scaling a cliff face, they’re immersed in the moment, their inner voice silent yet not absent. Should that seem a rather impoverished sort of being, Koch says it’s worth considering how many of our own experiences, from tying shoelaces to making love, are not self-conscious. He considers that faculty overrated. (For the record, Koch doesn’t lose sleep over swatting a mosquito in the middle of the night, but neither will he kill insects when he can avoid it.)

It’s impossible to know how cockroaches would perform in honeybee-style cognition tests as few have even been attempted in other insects. Perhaps honeybees are exceptional. But perhaps not, says the ethologist Mathieu Lihoreau. His 2012 article for the journal Insectes Sociaux, ‘The Social Biology of Domiciliary Cockroaches: Colony Structure, Kin Recognition and Collective Decisions’, co-authored with James Costa and Colette Rivault, is a must-read for anyone interested in these creatures.

When kept in isolation, individual roaches develop behavioural disorders; they possess rich spatial memories, which they use to navigate; and they might even recognise group members on an individual basis

Among the surprising — to me, anyway — facts detailed by Lihoreau, Costa and Rivault about Blattella germanica (the German, or small cockroach) and Periplaneta Americana (the American, or large cockroach), found in kitchens and sewers worldwide, is their rich social lives: one can think of them as living in herds. Groups decide collectively on where to feed and shelter, and there’s evidence of sophisticated communication, via chemical signals rather than dances. When kept in isolation, individual roaches develop behavioural disorders; they possess rich spatial memories, which they use to navigate; and they might even recognise group members on an individual basis. Few researchers have studied their cognition, says Lihoreau, but cockroaches likely possess ‘comparable faculties of associative learning, memory and communication’ to honeybees.

As to whether cockroaches possess a self, in the pages of Cockroaches: Ecology, Behavior, and Natural History (2007), co-written by William J Bell, Louis M Roth and Christine A Nalepa, I happened upon a reference to Archy, a popular early-20th-century cartoon cockroach who said: ‘Expression is the need of my soul.’ Archy’s inclusion was intended in fun, but there was a grain of truth. Cockroaches could very well possess a sense of self, and one that’s perhaps not entirely alien to our own.

As for how they fare in Backyard Brains, I do feel fewer misgivings now than when I started learning about insect inner experience. After talking with one of the company’s co-founders, a neuroscientist named Greg Gage, I came away impressed by his respect for the insects: if he doesn’t grant them sentience, he at least recognises the possibility that they feel pain, and encourages customers to care for their animals when experimentation has concluded. I also suspect that a cockroach, by the standards of its own experience, can live as fulfilling a life in research as under a sink. And though I still don’t like the thought of middle-schoolers doing the company’s experiments, at least its sensibilities are rather more compassionate than that of most people, who regard cockroaches as fair game for squashing.

Gage also justifies the costs to their insects by the benefits of teaching children about neuroscience in actual experiments — and they have conducted research to show those benefits are very tangible and real. It’s a legitimate argument. At the very least, though, the costs should be calculated as accurately as possible, in light of the sentience that cockroaches — and earthworms, and crickets — very likely possess. Maybe that means using fewer of them, or housing them with an eye to the dark, warm and moisture-rich conditions they naturally prefer. Perhaps it also means being thankful for them, and respectful, and actively trying to empathise with them.

I do wonder, however, whether both cockroaches and burgeoning scientific curiosities might be better served by studying cockroach behaviours and cognition in a less intrusive way. The Backyard Brains website admonishes against assuming a cockroach wants to keep its legs, but I don’t think Darwin would agree. He’d see this as a question to be tested, and one can envision the experiment: if, after making a choice, such as going through one of two doors, a cockroach has a leg removed, will he or she be as likely make that choice again?

That’s a bit gruesome, but other experiments in cockroach cognition would be fascinating. In the manner of honeybee learning experiments, squares and circles might be printed on the doors, with food placed behind one, in order to test whether cockroaches can learn shapes. To test spatial memory, the insects might be placed in mazes; and then, in light of research on how groups coordinate to find food, students might test whether large groups solve mazes faster. How do two roaches interact when they’re familiar with one another? What about when haven’t met before? If they’re closely related, or less so? Are these the results the same for males and females? And so on.

Let students do this sort of research, and leave the RoboRoach-ing and leg-cutting to those with an active interest in neuroscience, if only because cockroaches just might, however improbably, be happier that way. And to those who still consider that view soft-hearted and perhaps soft‑headed, I offer this: according to Gage, remote-controlled roaches respond to commands only for a while. After that, they ignore the signals. As best as we can tell, they go where they want to go.