The Spartans were the people and culture of an ancient Greek city-state on Earth, which existed in the mid-1st millennium BC.
In 480 BC, the Spartans, led by King Leonidas, defended a mountain pass for two days against a vast Persian army, in what was later known as the Battle of Thermopylae.
Julian Bashir got a new holoprogram of the Battle of Thermopyle in late 2375, where he described to Ezri Dax how "the Spartans lead a heroic struggle" against the Persians, until they were wiped out. In the holoprogram, Julian and Ezri were to play the role of the Spartans "fighting to the last man," in a battle he likened to the Battle of the Alamo. (DS9: "What You Leave Behind")
A living space could also be said to be spartan, meaning it lacked decoration and warmth. (ENT: "Fallen Hero",TNG: "Tin Man", "In Theory")