Thebes is a city in Boeotia, Greece. Thebes was founded by the Phoenician king Cadmus of Tyre, the brother of Queen Europa; he taught the Phoenician alphabet and built the citadel of Cadmea on the acropolis, while Amphion founded a seven-gated wall. Laius' pederastic rape of Chrysippus (which Greek mythology claimed was the first instance of mortal homosexuality) made Thebes famous for pedagogic pederasty. The well-defended city of Thebes withstood several Dorian sieges before falling, and Thebes and Athens went to war for the first time in 506 BC. During the Greco-Persian Wars, Thebes showed an unpatriotic attitude by submitting to the Persian invaders, fighting against their fellow Greeks at the Battle of Plataea in 479 BC.
The Greeks punished Thebes by depriving it of leadership over the Boeotian League, but, in 457 BC, Sparta decided to ally with Thebes to check Athens' growth in power. Thebes was restored to the leadership of the Boeotian League prior to the Peloponnesian War, and Thebes grew in power as an ally of Sparta. In 404 BC, urged the complete destruction of Athens, but, a year later, Thebes secretly supported the restoration of Athenian democracy in order to counter Sparta. In 395 BC, Thebes went to war with Sparta in the Corinthian War, and, while Thebes established a short-lived hegemony, they were defeated in 387 BC, and they were forced to grant autonomy to its subject villages. In 382 BC, a Spartan force occupied the citadel of Thebes, but, in 379 BC, the Spartan garrison was expelled and a democratic constitution was adopted. Thebes re-established its control over Boeotia, and its general Epaminondas was victorious at the Battle of Leuctra in 371 BC. The Thebans were hailed throughout Greece as champions of the oppressed, freeing many Spartan helot slaves and permanently crippling Spartan power. However, the death of Epaminondas at Mantinea in 362 BC led to the city returning to being a secondary power.
In the Third Sacred War of 356 BC-346 BC, Thebes called in Philip II of Macedon to defeat its enemy of Phocis, only to ally with Athens against Macedon as it expanded into Greece. In 335 BC, when the city rebelled against the new Macedonian king Alexander the Great, Alexander had the city destroyed and its population enslaved. Thebes was re-established in 315 BC by Cassander, but Thebes never regained its former prominence. It was besieged by Demetrius Poliorcetes in 293 BC and 292 BC, but it recovered its autonomy in 287 BC. It later fell under Roman and Byzantine rule, and it became a center of the silk trade. In 1146, the Normans severely plundered the city, and the Fourth Crusade of 1204 led to the Latin Empire conquering the city. Thebes then became a party of the Duchy of Athens, and Latin hegemony in Thebes lasted until 1458, when the Ottoman Empire conquered it, and it was under Turkish control until Greek independence in 1821, except for a Venetian interlude from 1687 to 1699. Today, Thebes is a bustling market town, and it had a population of 36,477 people in 2011.