Displacing the cows that grazed at the foot of the Washington Monument and the pigs that rolled in the muddy canal in front of the Capitol building, thousands of Union soldiers from around the country arrived in Washington in 1861 to prepare for battle. At the time, you could stroll into the White House on a whim, newly elected President Abraham Lincoln conducted official business from his room at the Willard Hotel, the Capitol’s iconic dome was still under construction, and the Sixth Street Wharf and Navy Yard were the busiest places in town.

By the time the Civil War ended four years later, D.C. was a changed city, and not just because of the assassination of its most prominent resident. “Hundreds of thousands of soldiers passed through Washington during the war, many of them coming back injured, which greatly altered the city’s landscape,” says Jim Barber, curator of the National Portrait Gallery’s “Mr. Lincoln’s Washington: A Civil War Portfolio.” Ahead of the 150th anniversary of the end of the war, the new exhibition gives us a glimpse of what our city looked like during the nation’s bloodiest conflict.

Patent Office: During the Civil War, the Patent Office served as a barracks, military hospital and morgue. Walt Whitman and Clara Barton were among the volunteer nurses who dressed soldiers’ wounds at the city’s third-oldest public building (which today houses the National Portrait Gallery and American Art Museum). Whitman once called the Patent Office “that noblest of Washington buildings.”
Guards at ferry landing on Mason’s Island examining a pass: To enter or exit the District and Alexandria, civilians and military alike needed to obtain travel passes. While this policy kept order, stories soon spread of border guards aiding in alcohol smuggling and of recently immigrated German-American guards “reading” passes upside down. “There’s a great example of a travel pass issued in 1865 to two young boys crossing the Aqueduct Bridge,” Barber says, “where the reason for travel is noted as ‘to skate and play.’ ”

The Old Capitol Prison, First and A streets NE: This unassuming brick building was constructed to temporarily accommodate Congress after the British burned down the Capitol in 1814. At the start of the Civil War, it served as a prison for Southern sympathizers, including infamous socialites-turned-Confederate spies Rose “Rebel Rose” Greenhow and Belle Boyd. The site was razed in the late 1920s and the U.S. Supreme Court building now stands in its place.

The Grand Review of the Army. Units of 20th Army Corps, Army of Georgia, passing on Pennsylvania Avenue near the Treasury: At the end of the war, the Union’s three main generals, Ulysses S. Grant, George G. Meade and William T. Sherman, paraded their victorious armies down Pennsylvania Avenue. “More than 100,000 soldiers participated in the parades, which took place on two consecutive days,” Barber says. “Just imagine what it would have been like for local residents.” (And you thought the 2013 inauguration was a noisy inconvenience.) If you squint really hard, you can see the newly completed Capitol dome in the distance.

National Portrait Gallery, Eighth and F streets NW; through Jan. 25, 2015, free; 202-633-8300. (Gallery Place)