The census was a mess. The United States’ population had changed dramatically over the previous decade, one marked by hundreds of thousands of unexpected deaths. One political party had lobbied for the addition of a citizenship question, complicating the already challenging task of counting those living within the country’s borders. And the whole process had taken months longer than expected to complete.

But the year was not 2020 — a count that officials promise will finally be released in the coming days.

It was 1870 — the first time the U.S. government had ordered a widespread census recount in response to public outrage that the numbers dictating the next 10 years of political representation and government funding were just plain wrong.

The outcry had begun in the South in the summer of 1870 while the enumerators were still counting. In Nashville and Memphis, the municipal governments, suspicious of the federal officials who had so recently been enemies during the Civil War, undertook their own censuses in parallel to the official count. From Mississippi to Kentucky to Maryland, communities raised concerns that certain segments of their population had been overlooked.

The Supreme Court dismissed a challenge to President Trump’s authority to exclude undocumented immigrants for each state’s congressional delegation size. (Luis Velarde/The Washington Post)

In September 1870, as the data continued to roll in, fears about an inaccurate count reached New York City. It seemed unlikely that the city’s recorded population would surpass 1 million people, news that Democratic Mayor A. Oakey Hall took as an affront to the city’s prosperity.

“The Federal census just taken is claimed to make apparent that our population has not increased in the past ten years!” he complained.

Philadelphia, at least, waited to level the worst of its accusations until the census in the city was completed in October 1870. The city had been heartened by early reports of its growth, but the final count was “grossly imperfect,” “startling and unsatisfactory,” the newspapers wrote.

In 1860, the census had recorded 565,529 people within the city’s limits. In 1870, that number was 657,179. According to the Census Office, Philadelphia had grown by approximately 16 percent over the decade. Some civic boosters had been promising a leap of 40, 50 or even 100 percent. There was one bright spot in the statistics, though: Philadelphia’s 16.25 percent increase was greater than the 14 percent increase accorded to New York City.

That civic competition — and not the chaotic aftermath of the Civil War — was the real challenge for the 1870 census, Superintendent of the Census Francis Walker came to believe.

The tumult of the previous decade had left communities without reliable estimates of their growth, which led to “wild and extravagant” expectations, he said. “Claims that were perhaps first made in the spirit of banter soon are taken as serious, and in the event people become angry to find that not true which was originally asserted only to irritate a rival.”

In New York, Mayor Hall and sympathetic newspapers charged that census officials with political motives had intentionally conducted the count during the summer, when many well-to-do citizens were out of town, and had intimidated residents of the city’s tenements, many of them immigrants.

Philadelphia’s City Council was finalizing plans to conduct a limited municipal recount, when it got word that New York had taken its grievances directly to Washington.

“New York has growled,” reported the Philadelphia Inquirer. President Ulysses S Grant responded by ordering the Census Office to conduct an official federal recount. This did not seem fair to the Philadelphia newspaper: “If the President wishes to do justice,” the Inquirer added, “he will determine that our census shall be retaken and thereby establish that a Philadelphia growl is as good as one uttered by New York.” In this, too, the cities were competitors.

Philadelphia got its recount. It took a week in November 1870 to re-canvass the city, with enumerators asking fewer questions of each household. The recount in New York took longer to orchestrate. By the time it got underway in late December, the revised population of its rival city to the south had already been calculated. The re-enumeration had added just 16,576 to the city’s total, leaving New Yorkers wondering if it was worth the aggravation of again blanketing their city with census takers. In the end, the do-over added about 18,000 to New York’s headcount, still short of its 1 million goal.

In 1871, a third city, Indianapolis, was also granted a recount. The city had grown a whopping 119 percent between 1860 and 1870 according to the initial numbers, but local officials were not satisfied. They believed Indianapolis to be larger still. The second survey of the city set its population at 49,411, more than 20 percent larger than census officials originally thought. City officials were unsurprised by this positive outcome; they had annexed additional land between the first count and the second to ensure it.

“Why cannot the census of New Orleans be retaken?” asked a Louisiana newspaper that thought the city’s count was some 30,000 shy. Though that may have been another case of civic pride gone astray, many scholars today consider the 1870 census to be among the least reliable available, because of significant undercounting in the South.

But there was at least one city not clamoring for a second look in 1870. The census had credited St. Louis with 310,864 residents — more than 10,000 greater than Chicago. There were widespread accusations of fraud, many leveled by Chicago politicians, but St. Louis kept its bragging rights for a decade. It wasn’t until 1880 — when St. Louis found its population had increased to just about 350,000 while Chicago boasted more than 500,000 — that St. Louis tried (and failed) to get its own recount.

Read more Retropolis: