In the Saharan regions of Africa around the sixth millennium B.C., 2,500 to 3,000 years before the great dynasties of Egypt rose along the Nile, a new way of life spread across the northeastern reaches of the world’s second largest continent. While the Sahara Desert was still relatively wet and green, nomads began to cross into the region, possibly from the Middle East, seeking more stable and plentiful lives. The traditional subsistence method of hunting and gathering was slowing giving way to a more secure practice, keeping a backup supply of food living right next to you through animal domestication and herding.

Around this time, some of the earliest ritual monuments to the dead were built by animal herders—only these cemeteries were built for cows, not humans.

“Cattle already, at a very early date, have social and probably symbolic significance in these societies,” says Paul Lane, the Jennifer Ward Oppenheimer Professor of the Deep History and Archaeology of Africa at Cambridge University. It’s not hard to see why early herders worshiped the docile and accompanying animals, which provided a reliable source of food and saved them from the hassle of tracking more elusive and dangerous prey.

But the early pastoralists still had their work cut out for them. As they moved into unfamiliar territory, they faced extreme landscapes, hostile neighbors and poorly understood climate patterns. In order to overcome these obstacles, ancient headers must have gathered from time to time to provide breeding opportunities for their animals and replenish lost livestock, not to mention renewing family ties and forging new bonds through the propagation of our own species. At the same time, periodic gatherings allowed the nomads to share advice about good pastures and warnings of danger in unfamiliar lands.

“If you are a lone dude with a herd, as soon as you lose your herd, you are done,” says Elizabeth Sawchuk, a post-doctoral archaeological researcher at Stony Brook University.

According to new archaeological research led by Sawchuk, early cattle cemeteries may have provided the assembly grounds that cemented networks of herders. These social gathering points allowed the pastoralists to spread through vast stretches of northern and eastern Africa over the millennia. Along with the bones of livestock, archaeologists have discovered colorful stone beads and other artifacts at the burial sites, suggesting the cemeteries played a critical role in early pastoralist life.

“We’re dealing with groups that have developed sophisticated social networks that they adapt and modify as they encounter new landscape challenges,” Lane says. “It’s about the beginnings of herding,” Sawchuk adds. “It’s really the thing that kicks off the east African pastoralist tradition.”

The beginning of cattle herding in Africa is contentious, but some of the first evidence for pastoralist ritual gathering dates to around 7,500 years ago at a cattle burial site in modern-day Egypt called Nabta Playa. This and other burials in the region, sometimes accompanied by megalithic standing stones, reveal that herders took the time to bury their animals, a significant ritual practice, even before they started burying each other.

But the good times quickly dried up for pastoralists of the Sahara. Desertification and conflicts with hunter-gatherer tribes sent the herders out from Egypt, some moving west as the desert dried, while others followed the lush Nile Valley to the south. At this point, humans start to show up in the huge cemetery mounds attributed to herders.

“We can see that these early pastoralists around the Nile are doing similar things to the people burying cattle were doing,” Sawchuk says, adding that these burials sometimes included family groupings.

Recently, Sawchuk was involved in a prominent dig at a monumental, roughly 5,000-year-old cemetery called Lothagam North Pillar on the shores of Lake Turkana in Kenya. The site is one of the largest such cemeteries discovered in the region to date, with an estimated 580 burials spanning a period as long as 900 years. It also contains the telltale signs of ancient herders—people who made their way even farther south from the Nile Valley. The dig revealed human remains along with vibrant stone beads, rodent teeth necklaces and other artifacts.

These grand cemeteries have long perplexed archaeologists because they contrast starkly with the burial practices of modern-day African pastoralists, which are influenced by religious conversion to Christianity or Islam. The massive group burials also differ from the customs of African herders encountered by colonial Europeans, who up until the early 20th century often left their dead out in the bush due to a belief that burying them would pollute the earth.

Sawchuk and a team of researchers are attempting to fit Lothagam North into the larger trend of monumental pastoralist cemeteries, spanning roughly 7,500 to 2,000 years ago, when the last pastoral burial sites, which had expanded to the Central Rift Valley by this point, mostly disappeared from the archaeological record of East Africa. The team published a study last month suggesting the grand cemeteries were among the first things that pastoralists created when they arrived in new territories. After all, one of the first places a culture on the move needs is a place to bury their dead.

Lothagam North shows a high degree of multi-generational planning, with bodies interred in such a way that they rarely overlapped with others. But what’s particularly unique about the Lothagam North site is the lack of hierarchy between the buried dead. This egalitarian approach to death separates these cemeteries from the monumental burials of agricultural societies. (Entire pyramids were built for certain pharaohs, while ancient Egyptian commoners were laid to rest in unmarked pits.)

“It’s really not about one person but about community,” Sawchuk says.

Lane, who was not involved in Sawchuk’s research, is in “broad agreement” with her argument that the ruins of cemeteries represent early pastoralism culture around Lake Turkana. It is difficult to follow the trajectory of these pastoralists from the Nile Valley into the Lake Turkana region, however, as the area between, South Sudan, lacks archaeological research due to current political volatility. But even so, Lothgam North and five other nearby cemeteries suggest the first herders arrived about 5,000 years ago.

“This is kind of a crazy time in the Turkana Basin,” Sawchuk says, explaining that the desertification of the Sahara led to the giant lake shrinking over time. The changing climate likely ruined some of the deep lake fishing enjoyed by communities around Turkana, but it also opened up fresh grassland in formerly submerged areas—perfect for grazing cattle.

Sawchuk is currently applying for grants to excavate Jarigole, another cemetery across the lake from Lothagam North, which is only just beginning to be explored. Many of the six sites around the lake occupy vantage points, and Sawchuk hopes to determine whether they were built by the same people and whether the network of burials was planned from the beginning.

Times eventually changed for the pastoralists, who in later years resorted to “bush burials,” leaving their dead in the wild without internment. Religious conversions meant a return to burying the dead, but never again in the same grand cemeteries where the herds of the past would gather. Sawchuk believes that the effort to build these sites became too burdensome, especially as towns grew more common and easier forms of networking appeared, such as marriage alliances, which are invisible to the archaeological record but still used today.

But in another sense, the lives of modern-day herders are intricately tied to their pastoralist ancestors. Traveling animal husbandmen continue to experience boom and bust cycles as they face extreme and unpredictable landscapes. And the ancient cemeteries, though abandoned, serve as a reminder of the critical support system that millions of herders in East Africa still rely on today, Sawchuk says. The persistence of pastoralism in East Africa is “why you see a Maasai warrior waving at you from the Nairobi airport when you land.”

As today’s wandering herders of Africa confront the changes and challenges of the future, they may take comfort in their ancestors’ steadfast ability to survive by relying on one another.