DAR ES SALAAM, Tanzania—Tucked away in a northern suburb of this sprawling East African city is a burial site that is evidence of one of the world’s great coronavirus coverups.

At the Kondo graveyard in Dar es Salaam, Tanzania, unmasked volunteers have been digging holes and felling trees to expand a compound that has tripled in size since last year. During the pandemic’s first wave, hazmat-suited government officials came at night to secretly bury the dead, graveyard workers and bereaved families said. Now, small groups of...

DAR ES SALAAM, Tanzania—Tucked away in a northern suburb of this sprawling East African city is a burial site that is evidence of one of the world’s great coronavirus coverups.

At the Kondo graveyard in Dar es Salaam, Tanzania, unmasked volunteers have been digging holes and felling trees to expand a compound that has tripled in size since last year. During the pandemic’s first wave, hazmat-suited government officials came at night to secretly bury the dead, graveyard workers and bereaved families said. Now, small groups of mourners gather for hasty ceremonies next to floral tributes.

Kondo’s gravediggers said those buried there since last year have one thing in common: All died as a result of the coronavirus, yet none were recorded as suffering from Covid-19. They said they know by speaking to the families and officials from the municipality.

“This is one of the government’s coronavirus cemeteries, but we’re not allowed to call it that,” said Said Ali Salum, a caretaker who has worked there so long that locals call him or “Mzee Wa-Makaburi,” or Mr. Graveyard. “We used to bury one a week [before the pandemic], but over the past year we have reached 17 a day.”

Tanzania, a country famous for Serengeti safaris and a turquoise coastline, has engaged in a grim experiment with implications beyond its borders: denying the existence of Covid-19. How that is playing out offers clues on the hidden toll of the pandemic across the developing world.

Last year, President John Magufuli declared the virus a “satanic myth” propagated by imperialist powers. While his neighbors sealed borders and locked down, his country of 58 million stayed open. His government barred doctors from registering coronavirus as the cause of death and labeled those who wore masks unpatriotic.

Seeking to keep the economy open and rally nationalist sentiment ahead of elections, he blocked foreign journalists from entering the country, rejected vaccines and refused to provide data to the World Health Organization. News organizations reporting on Covid-19 were shut down for “scaremongering,” and reporters threatened with jail.

By this spring, the president was dead, along with six other senior politicians and several of the country’s generals. The official cause of Mr. Magufuli’s death was heart failure. The details remain secret. Diplomats, analysts and opposition leaders say he had Covid-19.

Tanzania’s refusal to collect virus data is the most extreme example of the hidden toll of the pandemic in Africa, where few countries offer accurate counts of the sick and dead. Official figures show only 220,000 people have died on the continent, which has a total population of 1.3 billion, as a result of Covid-19. The U.S., population 330 million, has registered more than 750,000 Covid-19 deaths.

Scientists have partly attributed that lower count to criteria including youthful populations and better ventilated housing.

Even if Africa has fared better than hard-hit nations in the West, graveyards and mortuaries tell of a mortality rate far higher than the official numbers. In Uganda’s capital, Kampala, workers at the main Bukasa cemetery said the average number of daily burials has jumped from six to 30 since last year. Workers said relatives told them the extra deaths are from Covid-19. In the central morgue of Zambia’s capital, Lusaka, Covid-19 was present in 87% of all bodies in June, Boston University scientists found in a recent study.

The official death numbers are “epidemiologically impossible. The only sense that it makes is that we are not counting,” said Ayoade Alakija, co-chair of the African Union’s African Vaccine Delivery Alliance. “And of course we’re not counting—it’s glaring.”

Data gap

To bridge the data gaps, some scientists are looking to “excess mortality” figures—the number of deaths from any cause in a given period over a historical baseline from recent years—to build new estimates. One recent study by the Economist using machine learning estimated as many as 17 million people world-wide, more than three times the official number, had died of Covid-19. The official global death toll recently surpassed five million.

A man sold masks outside Regency Medical Center in Dar es Salaam. Hospitals are among the few places in Tanzania where masks are routinely worn.

The study didn’t put a figure on excess mortality in Africa, where data on mortality from all causes is limited. The United Nations says over half the countries there keep only handwritten death records, and 14 of those countries record at most only 10% of all deaths. Data scientists said the gap in Africa between recorded Covid-19 deaths and excess deaths is likely among the world’s most severe.

The Africa director at WHO, Matshidiso Moeti, said in October the organization estimated that about 59 million people in Africa had been infected with Covid-19 during the pandemic, even though only around 8.5 million cases have been officially recorded.

Underlining the problem is a lack of testing: African nations have tested just 70 million people for Covid-19, or around 5% of the population, according to WHO. In the U.S., for comparison, total tests number about 618 million, close to twice the population, according to the CDC.

Vaccines are also scarce across the continent. As the U.S. and Europe roll out booster shots, just 6% of sub-Saharan Africa’s 1.1 billion population has been fully vaccinated. Scientists said that creates a risk the continent could foster new and potentially more deadly variants.

In Tanzania, where the official Covid-19 death toll is 724, the Economist study estimated an excess mortality of up to 69,000 since the pandemic began.

Tanzania’s government said it stands by the figures issued by the national statistics agency, which registered zero new cases or deaths from May 2020 until June 2021. The Tanzanian president’s office referred questions to the health ministry, which didn’t respond to multiple requests for comment.

According to interviews with senior officials, doctors, mortuary workers and bereaved families, and an audit of graveyards, Covid-19 has likely killed thousands.

Dar es Salaam last month.

Around the start of this year, six senior politicians, including members of Mr. Magufuli’s cabinet, and several of his top generals died in quick succession from what the government labeled respiratory illnesses.

On March 17, the president, a dynamic 61-year-old known as “the Bulldozer” for his pugilistic approach to politics, was declared dead from what the government classified as heart complications. The government has declined to release details of his death, which took place in a heavily guarded hospital inside the National Intelligence Service compound.

Senior government officials, Western diplomats and Tanzanian opposition leaders say Mr. Magufuli contracted Covid-19 and was unconscious on a ventilator for a week before his breathing support was switched off.

With the former president’s allies still running the intelligence and security services, doctors and officials who administered Mr. Magufuli’s policy said they are too afraid to speak out.

Mr. Magufuli’s successor, Samia Suluhu Hassan, has slowly begun to re-engage with international agencies and has launched a tentative vaccine rollout. But with vaccine skepticism widespread after a year of official Covid denial, the shots have so far reached just 1.6% of the population, one of the lowest rates in the world.

At a vaccination hub in Dar es Salaam’s Tandale hospital on a recent day, nurse Davineth Lameck gestured to the empty waiting room. “We have administered seven shots today, and that was busy,” she said.

Davineth Lameck administered a vaccine last month. Tanzania has one of the lowest vaccination rates in the world.

Ms. Hassan, the president, has tried to shift attitudes. She was vaccinated live on state television and announced the government would allocate $2.2 million for pandemic research. She used her first address to the U.N. General Assembly in September to call for vaccine equity and the waiving of patent rights so developing countries could produce their own shots.

“It is indispensable that countries with surplus Covid-19 vaccine doses share them with other countries,” she said. “We tend to forget that no one is safe until everyone is safe.”

Tanzania in July received its first one million vaccine doses from the U.S. via Covax, a coalition of global organizations including WHO that are working to distribute vaccines, and one million doses of China’s Sinopharm vaccine arrived last month.

Opposition groups say there are signs Ms. Hassan is continuing with Mr. Magufuli’s authoritarian approach. Freeman Mbowe, leader of the main opposition Chadema party, has been held on terror charges since July, when he was arrested with several other party officials hours before a planned address on proposed constitutional reforms.

‘Covid free’

Back in April 2020, Mr. Magufuli stood in front of hundreds of unmasked worshipers in the Dodoma Cathedral to make a declaration televised live to the nation. “The corona disease has been eliminated thanks to God,” he said, raising an index finger. “Tanzania is now Covid free.”

In the weeks prior, Mr. Magufuli, who frequently cited his doctorate in chemistry, had abandoned his government’s policy of coronavirus prevention and dissolved the health ministry’s Covid-19 response team that was established in consultation with WHO.

The church speech was the climax of three days of nationwide prayer he said had delivered the virus a mortal blow. The few Covid-19 restrictions still in place would be lifted, he added.

In May, a disturbing split-screen began to emerge. Government loyalists organized a “corona festival” in Dar es Salaam. Thousands poured into a city sports ground after fliers posted around the city promised dancing and cocktails.

A few kilometers away, in the sprawling suburb of Tabata, the virus was raging. In the space of three weeks, Richard Manongo, a 36-year-old chef, lost four members of his family and almost died himself.

“We were all living in the same house. All of sudden my uncle, aunt and two of my cousins aged 32 and 29 were gone,” Mr. Manongo said, recalling the chorus of wheezing through the night. When he tried to take his ailing relatives to the central Mikocheni hospital, he was told there was no oxygen supply. Patients with Covid-19-like symptoms were being kept in isolation, the doctors told him, because staff were too afraid to treat them.

“When they passed, the government came at night and took the bodies away,” he said. “On the death certificate they wrote ‘acute pneumonia.’ ”

Richard Manongo, a chef at The Tea Spot cafe in Dar es Salaam, lost four members of his family and almost died himself.

In the days after Mr. Magufuli declared the virus over, officials in neighboring Uganda began to notice a surging positivity rate from Tanzanian truck drivers. On a single day—May 15—every one of the 43 people who tested positive in the country were Tanzanian truckers crossing the border, forcing the government to close it. Four Tanzanians died at the wheel of their trucks waiting for a test.

In June 2020, Mr. Magufuli confirmed the government had stopped releasing Covid-19 data as of the previous month, including case numbers and deaths, saying it was “fueling public panic.” He said figures showing a rise in infections were the result of faulty testing, saying intelligence agents had sent the national laboratory random nonhuman samples of animals and fruits—including a sheep, a goat and a pawpaw—that came out positive. Mr. Magufuli dismissed the national lab chief and installed a loyalist.

The former lab chief didn’t respond to calls for comment.

In Dar es Salaam’s hospitals, doctors were wrestling with how to treat patients they knew had a disease the government said no longer existed.

“The word Covid-19 was not allowed,” said one doctor at Muhimbili National Hospital, the country’s largest. Medics were told by health ministry officials to list people with coronavirus symptoms as suffering from acute pneumonia and were instructed to treat them alongside other patients. “We had old men with diabetes in the same ward as Covid suspects…people were dying from lack of treatment,” the doctor said.

The health ministry told the public to use the alternative treatments favored by Mr. Magufuli. At Kinondoni hospital, around 5 kilometers from Muhimbili, hundreds of sick people lined up to enter newly constructed steam therapy booths they were told would sweat away the virus. Commercials on state television extolled the virtues of Covidol, an herbal syrup made by the Tanzania Industrial Research and Development Organization, a government-funded research group.

Officials touted steam therapy booths to protect against and treat Covid-19. Men used a booth in Dar es Salaam in May 2020.

Photo: ericky boniphace/Agence France-Presse/Getty Images

In July, as thousands of accounts on Tanzanian social media posted videos of the secret government night burials, Mr. Magufuli passed more regulations to control reporting on the pandemic. Any person or institution posting about Covid online would be fined a minimum of $1,800 or face a minimum of one year in jail.

The government revoked the license of Kwanza TV, an opposition-affiliated broadcaster, citing an Instagram post reporting on a travel alert issued by the U.S. Embassy in Dar es Salaam saying the risk of contracting Covid-19 was extremely high.

“We were summoned, and the entire state apparatus was deployed against us,” said Maria Sarungi, Kwanza TV’s owner, who later fled into exile for fear of retribution. “From that point, the media was basically banned from printing the word ‘Covid-19’ about Tanzania.”

Mr. Magufuli was anxious to make sure the pandemic wouldn’t derail his plans for a second five-year term in elections slated for that October, Tanzanian political analysts said.

His ruling Party of the Revolution, which has controlled Tanzania since the party’s creation in 1977, gathered huge crowds for a nationwide campaign presented as a return to the nationalistic leadership of Julius Nyerere, Tanzania’s founding father and an icon of anti-colonialism in Africa.

Mr. Magufuli campaigned on pledges to resuscitate the national airline, launch a modern railway and revive work on a hydroelectric dam first proposed by Mr. Nyerere in the 1970s. He also railed against the virus, and the vaccines being developed to combat it.

“Vaccinations are dangerous. If the white man was able to come up with vaccinations, he should have found a vaccination for AIDS by now,” he said.

Supported by a pliant media barred from reporting on the virus, Mr. Magufuli won 84% of the vote amid widespread accusations of irregularities. His victory coincided with the beginning of a vicious second wave of the virus.

Workers at a fish market in Dar es Salaam last month.

Doctors afraid to speak

Around the turn of the year, government officials and generals died in quick succession, including Mr. Magufuli’s chief secretary and key political ally, John Kijazi.

Mr. Magufuli, still denying the existence of the virus, had retreated to his ancestral village of Chato, refusing to return to the capital. Reports of deaths became so frequent the word “pole,” Swahili for sorry, trended on Twitter. Father Charles Kitima, secretary of the Tanzania Episcopal Conference, warned of a sharp increase in the number of funerals. The Catholic Church’s leadership in Tanzania said some 30 priests and 60 nuns had died in two months after reporting breathing difficulties.

“I was selling seven or eight every day,” said Kennedy Morris, who runs one of the dozen small roadside kiosks that sell caskets in the Manzese district of Dar es Salaam. “In the pre-pandemic days I would sell two or three.”

By early February, amid rising public panic, Health Minister Dorothy Gwajima called a press conference that looked a lot like a cooking show. Standing with deputies, she drank blended smoothie-like concoctions containing ginger, garlic and lemons to assure the public that the best way to beat acute pneumonia was through natural remedies.

“The government has no plans to receive Covid-19 vaccines that are being distributed in other countries,’’ Dr. Gwajima said, before covering herself with a blanket to inhale steam from a saucepan of herbs.

Two weeks later, Mr. Magufuli returned to the capital for the first time in almost five months, coinciding with the death of Seif Sharif Hamad, the vice president of Zanzibar, which operates as a semiautonomous state within Tanzania. Mr. Hamad, who wasn’t a member of the ruling party, was the first senior official to admit he had contracted Covid-19. Mr. Magufuli offered his condolences in a statement but didn’t mention the cause of death.

Former President John Magufuli in February, shortly before his death.

Photo: Emmanuel Herman/Reuters

Several days later, Finance Minister Phillip Mpango appeared on state television from a hospital to quash rumors that he, too, had died of Covid-19. “I came to the hospital with my oxygen cylinder but in the last three days I did not use it because my health has improved,” he spluttered, unmasked and sitting next to unmasked doctors, coughing so violently he was barely able to speak. Mr. Mpango recovered and is now Tanzania’s vice president under Ms. Hassan.

WHO chief Tedros Adhanom Ghebreyesus released a statement in February warning Tanzania to take “robust action” and resume collecting and sharing Covid-19 data.

At the Kondo graveyard, Mr. Ali Salum, the caretaker, was clearing more trees to make room for the rising body count. “When we heard the president saying there was no Covid we felt awful,” he said. “How many have died for this lie?”

On Feb. 22, Mr. Magufuli gave another landmark speech at the Dodoma Cathedral, conceding that the virus was still circulating in Tanzania. For the first time, he urged people to wear masks, but only locally manufactured ones. “Foreign masks are dangerous,” he said.

On Feb. 27, he appeared again in public unmasked, laughing and joking at the swearing-in ceremony of his new chief secretary, to replace the one who died. It was the last time he would be seen in public alive.

A discarded mask outside Muhimbili National Hospital last month.

Write to Joe Parkinson at joe.parkinson@wsj.com