BUENOS AIRES — As Concepción Martínez, her husband and two daughters pulled into the last subway station here, cheers and clapping erupted from the throngs of people, some wearing turn-of-the-20th-century dress, waiting on the platform.

Camera flashes lighted the tunnels as passengers took their final rides in the saloonlike wagons — with their wooden benches, frosted glass lamps and manually operated brass doors — of South America’s first subway line.

“Every day, I ride this train into work, so this is a kind of goodbye,” Ms. Martínez said.

The antique Belgian-built cars, a symbol of Buenos Aires’s early-20th-century wealth, were taken out of service this year, and their retirement is a poignant example of the city’s struggle to preserve its physical history as some of its icons and infrastructure crumble.

An audit last fall cautioned that much of Buenos Aires’s underground transit system was in a dangerous state of disrepair, and that the city’s oldest line — linking the presidential mansion, the Casa Rosada, and the Once train station south of downtown — should be removed from service immediately.