ACCRA, Ghana — On a blistering hot day last week, a team of Ghanaians clambered out of vans into Agbogbloshie, a notoriously poor neighborhood in the capital city of Accra. Their eyes roamed over the countless items for sale in this area that is part slum, part scrap metal yard, part market: gas ovens and barbecues, hand saws and oversize spoons, roosters and vegetables and shoes.

But they hadn’t come to buy anything. They were there to hunt for data.

Ghana is preparing to conduct a census next March — this was a trial run. The people picking their way through the heaps of wares were enumerators, census takers who canvass assigned areas. They joined the locals in their small stalls and asked questions like, “Can you read and write?” and “Do you have access to a toilet?” It wasn’t an easy place to conduct an interview — nearby, men were burning electronic waste to extract the metal in it, adding to the heat and polluting the air.

But the enumerators were determined. And for the first time, instead of the pens and papers census takers were equipped with in the past, they were carrying around digital tablets — just one sign that Ghana is taking a new approach to data.

I had the opportunity to observe them on a trip sponsored by the Global Partnership for Sustainable Development Data, hosted at the United Nations Foundation, which supports UN causes. They invited journalists to explore how Ghana and other West African countries are changing their development strategy. What emerged clearly was a growing belief in the region that if you want to fight poverty, you need evidence-based thinking and plenty of good data.

The census is a huge part of that. Although it can be easy to overlook, it’s actually incredibly important because its data informs the government decisions that shape millions of lives.

Recognizing this, Ghana wants its new census data to be more accurate, comprehensive, and granular than in the past. In addition to switching to digital tablets, it’s using satellite imagery to make sure households in rural areas don’t go undiscovered and uncounted, and disaggregating the data it collects at the district level.

The government is now seriously committed to a “leave no one behind” ethic, which means counting every single person in the population. That includes people who are sometimes called “the invisible” — those who live in slums, who are homeless, or who are institutionalized.

These people are harder to reach, but without counting them and identifying which places they’re concentrated in and which services they lack, it’s difficult to design targeted interventions that will actually help them. Ghana and other West African countries are increasingly treating this kind of data-driven approach as crucial to their development.

Ghana’s road to a more data-driven development strategy

Sometimes called West Africa’s “golden child,” Ghana was the first country in sub-Saharan Africa to cut its poverty rate in half, thereby achieving the first of the UN’s Millennium Development Goals, a list of eight targets that world leaders pledged to meet by 2015.

By 2013, Ghana had already lowered its poverty rate from 52 percent to 24 percent of the population, according to Omar Seidu, the principal statistician at the Ghana Statistical Service.

That sounds impressive, but when researchers disaggregated the data they found that in some regions, over 70 percent of people were still below the poverty line, Seidu said. In two districts in a particularly poor region, it was as many as nine out of 10 people.

“Sometimes, hidden within the global data, there are inequities. You have to unpack the data to reveal that,” said Anthony Ofosu, a deputy director at the Ghana Health Service. He added that it’s important to disaggregate the data not only by geographical area, but also by gender and age, so as to get information on issues like maternal mortality and child poverty.

One of the major critiques of the Millennium Development Goals was that some countries saw improved conditions for people who were just below the poverty line, but the extremely poor weren’t better off. So when the UN formulated a new list of targets in 2015, dubbed the Sustainable Development Goals, it emphasized the motto “leave no one behind” as a guiding principle. Those words have become a popular development slogan.

“If you don’t want to leave anyone behind,” Seidu said, “you need to have basic information about people at every level of society.”

Ghana hopes to inspire neighbors in the region to increasingly adopt this data-driven approach, which has found strong supporters among the country’s current political leaders.

At a May 21 dinner for visiting journalists in Accra, Vice President Mahamudu Bawumia, an economist, spoke glowingly about the many new ways his country is leveraging data. That includes a biometric national ID system (more than a million Ghanaians have registered for it so far) and a digital address system (whereby every five square meters in the country has its own unique address).

“This way you can target services to people, once you know where they are,” Bawumia said. In the course of a five-minute speech, he used the word “evidence” three times.

How do you count “the invisible”?

Ghana’s census will take place over three weeks next March, not a lot of time to survey a population of approximately 30 million people. But the preparations begin well in advance, and this time, they include a lot of help from new technology.

For the first time, enumerators will use digital tablets to survey the population, which will allow answers to be checked for inconsistencies or omissions in real time. Electronic maps will help enumerators make sure they’re counting everyone in their demarcated area. GPS will pinpoint and record the exact location where each interview was conducted.

Meanwhile, government officials will be using satellite imagery to identify all housing structures in the country. After the enumerators go out into the field, an image showing which locations they’ve covered will be overlaid on top of the satellite imagery.

“This allows us to determine which areas may have been missed,” explained Araba Forson, a chief statistician for the Ghana Statistical Service. “Usually it’s in farming areas, enumerators may not have known people are living there.”

Ghana is spending $84 million to carry out the 2020 census, Forson said, compared to $54 million in 2010. Adding the new technological bells and whistles is a big investment, but the government considers it worthwhile because census data is the bedrock upon which so much policy rests.

On the night of March 15, enumerators will go out and endeavor to count all the people sleeping outdoors. They’ll wake up the sleepers and run through an abridged questionnaire with them, then give them a certificate to show they’ve been counted.

The “leave no one behind” agenda also means that enumerators will go to hospitals to count the people there. I tagged along with them to the Accra Psychiatric Hospital, a resource-strapped institution currently treating 379 patients, some voluntary and some involuntary, who are dealing with issues ranging from depression to psychosis. Due to lack of space, some patients sleep outdoors in a courtyard, where a motley collection of hospital beds and old-fashioned wooden beds are draped in mosquito nets.

Here, enumerators can’t survey patients directly. So instead they interview the hospital staff, who look through the patients’ records to provide answers about them. The main challenge for the enumerators is that sometimes these records are spotty and don’t contain basic pieces of information, like the patients’ ethnicity.

Nevertheless, the enumerators go from locked ward to locked ward to interview nurses and administrators, who sit behind desks piled high with paper records and go through them one by one. On their tablets, enumerators record the precise location of each building they’ve visited.

It’s painstaking work, but Forson said the lessons Ghana learns from this process will be passed along to other African countries like Sierra Leone and Senegal — signaling perhaps the growing embrace of evidence-based thinking and data-driven approaches in developing countries.

Sign up for the Future Perfect newsletter. Twice a week, you’ll get a roundup of ideas and solutions for tackling our biggest challenges: improving public health, decreasing human and animal suffering, easing catastrophic risks, and — to put it simply — getting better at doing good.