The battle of Piraeus (403 BC) saw the Spartans defeat the pro-democratic forces of Thrasybulus outside the port of Athens, but divisions within the Spartan leadership meant that the Athenians were still able to restore their democracy.
At the end of the Great Peloponnesian War in 404 BC the Spartan leader Lysander had imposed an oligarchy on Athens, led by a Council of Thirty. This group quickly turned into the 'Thirty Tyrants', and began a purge of their opponents, possible opponents and anyone whose wealth they wanted. They then restricted power to a selected group, the 'Three Thousand', and expelled all other citizens from the city. Many went into exile in Thebes or other nearby cities, or moved to the port of Athens at Piraeus.
Amongst the exiles was Thrasybulus, one of the more successful Athenian commanders in the later stages of the Great Peloponnesian War, and a proven leader of the democratic faction during the short-lived rule of the Four Hundred. As the Thirty tightened their grip he fled to Thebes, where he gathered a small group of around 70 followers. Early in 403 BC they crossed back into Attica and captured the fort of Phyle, twenty miles to the north west of Athens. The Thirty responded by mobilizing the 'Three Thousand' and advancing towards Phyle. An initial assault was repulsed with some ease, and an attempt to besiege the fort was foiled by heavy snow. They then sent their Spartan allies to blockade Phyle, but Thrasybulus launched a surprise dawn attack on their camp and forced them to flee.
By now Thrasybulus had at least 1,000 men, and he decided to risk a move to Piraeus, where there were several thousand dispossessed democrats. The port was also vulnerable to attack after the Spartans insisted that its walls be dismantled. The Thirty responded quickly to this threat, but suffered a significant defeat during an attempt to attack the Democrat position on Munychia Hill, just to the north-east of Piraeus (battle of Munychia, 403 BC). During this battle Critias, the leader of the Thirty was killed. The Thirty had already begun to lose their nerve after the setbacks at Phyle, and they now found that their chosen electorate, the Three Thousand, had turned against them. The Thirty were dismissed and a new Council of Ten, with one representative from each tribe, was put in its place. Two of the Ten came from the Thirty, but the rest fled to Eleusis. There were now three power bases in Attica - Thrasybulus and the Democrats at Piraeus were in the strongest position, and had momentum behind them. The Ten and the more moderate oligarchs still had control of Athens, but they were increasingly nervous, sleeping with their weapons close to hand. The survivors of the Thirty, with their more extreme supporters, were holed up at Eleusis.
Two more factions would soon enter the picture, both from Sparta. Both the Thirty and the Ten called for help from Sparta. Lysander, whose arrangements were unravelling, was only too willing to help. He convinced the Spartan authorities to appoint him as harmost and his brother Libys as navarch. The oligarchs were loaned 100 talents, and a fleet of forty triremes was gathered. Diodorus says that Lysander had 1,000 troops, which he took to Eleusis, where he began to recruit mercenaries, while Libys blockaded Piraeus, cutting off the Democrats supplies and causing food to run short.
The exact motives of the Spartan establishment aren't clear at this point. While Lysander was preparing to restore the oligarchy, King Pausanias was agitating for command of the campaign. As king he needed some military achievements to build up his prestige, and he convinced three of the five ephors to give him command of a full Peloponnesian army. Corinth and Thebes both refused to contribute to this expedition, not wanting to see Athens dominated by Sparta, but Pausanias was still able to gather quite a sizable force, which he took to Athens. Lysander was forced to acknowledge the king's authority, and the two Spartan forces merged. Was isn't clear is what sort of settlement Pausanias wanted at this point - was he planning to restore the democracy all along, or did he originally just want the credit for restoring Lysander's system.
The Spartan army camped on the plain of Halipedum (possibly just to the east of Piraeus), with Pausanias on the right and Lysander on the left. The king's first move was diplomatic - he sent envoys to Piraeus to order the democrats to return to their homes. After they refused to obey he launched a brief attack on their defences, but then returned to his camp.
On the following day Pausanias took two Spartan morai and the cavalry from three Athenian tribes around to the 'Still Harbour', probably to the west of Piraeus, to examine the probable location for a siege wall.
As Pausanias and his men were returning from this expedition, the Democrats took the chance to attack his isolated formations, sending light troops to harass him. Pausanias responded vigorously, ordering the cavalry and the youngest hoplites (those between 20 and 29) to attack, while followed up with the rest of his hoplites. The Democrats were forced back into the town, and lost thirty men before they reached the theatre of Piraeus.
The Spartans had accidently advanced into a very dangerous position, for the rest of the Democratic light troops and their hoplites were arming in the theatre. The light troops rushed to the rescue of their colleagues, and forced the Spartans into a fighting retreat. Although the Spartans held their formation during this retreat, two regimental commanders (Chaeron and Thibrachus), and Lacrates, an Olympic champion, were killed during the retreat. Thrasybulus and the Democrat hoplites then arrived, and took up a position in front of their light troops, forming in eight ranks,
Pausanias's entire force was now united, and took up a defensive position on a hill a short distance from the port, from where he summoned aid from his main army. Once these troops arrived he formed them into a much deeper formation, indicating that the Democrats were probably badly outnumbered, and launched an attack. The Democrats chose to stand and fight, but were eventually forced to retreat. Some were pushed into the swamp of Halae, and others were forced to retreat back into the port. The Democrats lost 150 men in this part of the battle.
The fighting was now over. The Spartans lost at least 13 men, who were later buried outside the Kerameikos Gate of Athens. The tomb has been excavating, revealing that one man had a spear point in his ribs and another had two bronze arrowheads in the leg. The Democrats had lost at least 180 men in the different phases of the battle. Pausanias was able to erect a trophy commemorating his victory, and then returned to his camp.
At this point the Democratic revival looked to be in trouble, but Pausanias now appeared as their saviour. By now he had decided that he didn’t want Lysander's men to keep control in Athens. He sent a secret message to the democrats telling them to send ambassadors to him and the two ephors who were with him, and also telling them what to propose. The Democrats followed these suggestions. He also convinced some men from the city to come forward and declare that they didn’t want to be at war with the people at Piraeus. The ephors sent both sets of envoys to Sparta. The Ten responded by sending their own ambassadors to Sparta. Both sides were heard by the Spartan Assembly, which then decided to send fifteen commissioners to Athens to work with Pausanias and arrange a reconciliation between the two sides.
An agreement was soon worked out. Everyone was to return to their homes apart from the Thirty, the Eleven, and the Ten who had controlled Piraeus for the Thirty. Anyone who feared for their future in Athens was allowed to settle in Eleusis. Once this agreement was in place Pausanias disbanded his army. Thrasybulus and his men were taking no chances, and on their first visit to Athens, to offer sacrifices to Athena on the Acropolis, went fully armed. Thrasybulus then issued a verbal scolding to the defeated oligarchs, but for the majority of the Three Thousand that was their only punishment. The previous democratic system was restored after a gap of only a year.
Pausanias was later put on trial at Sparta for his actions at Athens, but was narrowly acquitted. In 402-400 Athens loyally supported Sparta in her war with Elis, but it didn't take long for the rivalry between the two cities to break out once again, and in 395 they formed an alliance with Thebes against Sparta (Corinthian War).