Scientists have mapped every single nerve cell of an adult fruit fly brain with the aim to understand more about how humans think and behave.

It is the first time a wiring diagram has been created of an entire brain of an animal that can walk, see, sing and dance, the researchers said.

The map shows how the brain’s 140,000 neurons, or nerve cells, make close to 50 million connections between them.

By comparison, the human brain contains around 87 billion neurons.

Despite the size difference, the researchers said their findings, published in a series of nine papers in the journal Nature, could help shed light on how the human brain works as both are built similarly.

Dr Gregory Jefferis, from the Medical Research Council’s (MRC) laboratory of molecular biology and from the University of Cambridge, who was one of the co-leaders of the research, said: “If we want to understand how the brain works, we need a mechanistic understanding of how all the neurons fit together and let you think.

“For most brains we have no idea how these networks function.

“Flies can do all kinds of complicated things like walk, fly, navigate, and the males sing to the females.

“Brain wiring diagrams are a first step towards understanding everything we’re interested in – how we control our movement, answer the telephone or recognise a friend.”

An international team of scientists called the FlyWire Consortium created the highly-detailed map after analysing more than 100 terabytes of image data, which is equivalent to the storage available in 100 typical laptops, and enlisting the help of artificial intelligence.

Dr Philipp Schlegel, the first author of one of the studies, from the MRC laboratory of molecular biology, said: “This dataset is a bit like Google Maps but for brains: the raw wiring diagram between neurons is like knowing which structures on satellite images of the Earth correspond to streets and buildings.

“Annotating neurons is like adding the names for streets and towns, business opening times, phone numbers, reviews, etc, to the map – you need both for it to be really useful.”

The research was funded by the US National Institutes of Health BRAIN Initiative, Wellcome, Medical Research Council – which is the UK’s leading publicly funded biomedical research organisation and is part of UK Research and Innovation (UKRI) – Princeton University, and National Science Foundation.

The hope is the research could lead to targeted treatments for brain diseases.

John Ngai, director of NIH’s BRAIN Initiative, said: “In many respects, it (the brain) is more powerful than any human-made computer, yet for the most part we still do not understand its underlying logic.

“Without a detailed understanding of how neurons connect with one another, we won’t have a basic understanding of what goes right in a healthy brain or what goes wrong in disease.”