To avoid infections, a typist wears a mask in New York City in 1918. (U.S. National Archives and Records Administration)

In 1793, New York created its first health department in hopes of staving off a yellow fever outbreak that had occurred in Philadelphia. It was too little, too late: Despite the best efforts of early public health officials, a yellow fever epidemic reached the city, killing hundreds of New Yorkers and causing others to flee.

It would not be the last time the city contended with a widespread disease outbreak. “Germ City,” a new exhibition at the Museum of the City of New York, curated with the help of the New York Academy of Medicine, tells the story of the metropolis’s long history with microbes.

It’s a pairing fraught with historical significance. Over the years, the metropolis has coped with various epidemics, from yellow fever in the early 19th century to HIV/AIDS in the 1980s. Confronting these emergencies wasn’t always easy: It involved medical professionals, city officials and community leaders.

The exhibition is timed for the 100th anniversary of the influenza pandemic that swept through the city in 1918, killing 33,000 New Yorkers. That tally was actually a victory: The city had a lower death rate than its neighbors, and officials used public health strategies such as an education campaign against spitting to keep people from getting sick.

“Germ City” tells that story and others, but it doesn’t stop there. Historical artifacts are displayed alongside contemporary artwork addressing social and political questions raised by a city’s battles with sickness. The exhibition looks at advances in treatment and the city’s many quarantines and sanitation struggles. Visitors can attend such events as a panel discussion on disparity and epidemics — featuring a pop-up flu-shot clinic — and a walking tour of the hospital zone at Ellis Island.

Can’t make it to New York? The exhibition’s website showcases many of the artifacts on display at the museum.