Rick Maiman / AP Images

By late March 1863, hundreds had died in Alexandria, Virginia. The mortality rate had almost doubled in just one night, and even quadrupled in other parts of the country. Three thousand people were dead in less than a month in North and South Carolina. The numbers in Louisiana, Georgia, and parts of Mississippi were equally as high. As a smallpox epidemic tore through the country, more than 49,000 people died from June 1865 to December 1867, the years an official count was kept.

Smallpox exploded at this time not because of a lack of protocols or knowledge—a vaccine even existed—but because political leaders simply didn’t care about the group that was getting sick. Government inaction or delay—due to racial discrimination, homophobia, stigma, and apathy—have shaped the course of many epidemics in our country. In the 1980s, for example, HIV spread as the government barely acknowledged its existence.

Now the United States is facing the coronavirus pandemic. Once again, the threat a disease poses has been magnified by the slow speed with which the government has reacted. And although this disease is not concentrated within any one community, it is poised to exacerbate existing inequalities. The lesson of past outbreaks of infectious diseases is that public officials must take them seriously, communicate honestly, and tend to the most vulnerable. If the United States has not always lived up to that standard, we now have the perfect opportunity to apply the lessons of our past mistakes.

When the first cases of smallpox broke out among troops during the Civil War, military officials—on the Union and Confederate sides alike—immediately quarantined the infected in a tent or a makeshift hospital to prevent the transmission of the virus. But when smallpox began spreading among formerly enslaved people, officials either ignored it or argued that the virus spread viciously among black people because of racial inferiority and unsanitary habits.

The outbreak shouldn’t have happened. Medical authorities had long-established procedures to respond to epidemics, and smallpox was not a mystery. In the summer of 1721, at the height of a smallpox epidemic in Boston, an enslaved African named Onesimus explained the process of inoculation, which had been prominent for centuries in Asia and Africa, to the Puritan minister Cotton Mather. The process of injecting lymph, the colorless fluid that oozed from under a smallpox vesicle, into a healthy person created a mild version in its host, who thereby gained immunity. In 1796, Edward Jenner, an English physician, developed a vaccine for smallpox by using the lymph from infected cows. While many Civil War doctors doubted the efficacy of the vaccine or simply struggled to properly administer it, preventive protocols to protect the population did exist. Quarantine as a practice had originated in 14th-century Venice.

Yet federal and military authorities forced freedpeople—sick and well—into makeshift camps, placing them, in effect, under lockdown together, leading to the explosive spread of the virus throughout the African American community.

In the months after President Lincoln had issued the Emancipation Proclamation in January of 1863, no infrastructure was in place to provide new freedpeople with basic necessities, let alone to combat a deadly virus. Mortality rates increased. In the face of a widespread epidemic, the people had to help themselves in order to survive. Harriet Jacobs, a formerly enslaved woman who had escaped to the North but returned to the South to help, wrote to charitable groups and asked them to immediately send clothing, blankets, and other resources. With the money Northern benevolent associations sent, Jacobs, with the eventual assistance of the military, constructed a makeshift hospital for freedpeople.

In Baltimore, Miss Downs, a black woman who operated a boardinghouse, used her small income to care for children orphaned by smallpox. C. E. McKay, a white reformer, wrote in a newsletter that part of Downs’s income had been “expended in medicines for one of the little orphans, who is dropsical, her head and neck swelled to an unnatural size, and her arms and legs slender as pipes.” Downs wasn’t the only person to open her home to the orphans. Black women in many communities took in children who lost their parents to smallpox. Evidence of how African Americans had to care for themselves during the epidemic, like McKay’s report, are buried in diaries and Northern benevolent associations’ newsletters, not in government records, as the health of their communities suffered well into the 20th century.

In the 1980s, the medical community struggled to define the pathology behind a new illness.  Doctors and researchers described it as “the gay plague,” “gay cancer,” or its scientific euphemism, GRID, which stood for “gay-related immune deficiency.” Scientists later made a more precise definition, separating the presence of the virus and its behavior, referring to the former as HIV, human immunodeficiency virus, and the latter as AIDS, acquired immunodeficiency syndrome.

Some claim today that President Donald Trump’s dismantling of the National Security Council’s pandemic team in 2018 exacerbated the government’s ability to quickly respond to the coronavirus pandemic. The same can be said about the AIDS epidemic. As the Harvard professor David Jones has recently pointed out in the New England Journal of Medicine, “esteemed microbiologists Macfarlane Burnet and David White predicted in 1972 that ‘the most likely forecast about the future of infectious diseases is that it will be very dull’” due to the rise of antibiotics and immunizations. By the early 1980s, as more funding went to cancer research, many departments of virology had dissipated. So when HIV emerged, many incorrectly identified it as a cancer. The failure to identify HIV as a virus, let alone as a retrovirus, led to its further spread and dramatically slowed down diagnoses.

But even this fallout was not the biggest threat to the people affected. Like smallpox among newly freedpeople, HIV was seen as an epidemic that only affected a marginalized minority: gay men. Many within the Ronald Reagan administration refused to even acknowledge the epidemic. And when they did, they joked about it. Though HIV presented much more of a medical and scientific question than coronavirus or smallpox, apathy proved to be as lethal as the virus.

History has shown us time and time again that epidemics worsen when the federal and state leaders with the power to implement preventive efforts fail to take it seriously. In the past few years, public-health and national-security officials have issued warnings that the U.S. was not ready for a pandemic, but the government failed to act then. Now the coronavirus is in all 50 states. In the 1860s and in the 1980s, communities had to find a way to help themselves. Today the government has a chance to not make the same mistake again.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.