FYI: With a little imagination, while in Athens, and on a clear day, one can still make out the scene of part of this naval encounter from the Acropolis! Mount Lykavittos is an even better vantage point.
In September of 480 BC the Persians navy had recently suffered the loss of several ships during the sea battle off Artemisio and the accompanying storm.
Simultaneously, landside, the Persians had turned the Spartan 400 and Platean defense at Thermopylae and marched deep into southern Greece.
The Attik Greeks, vastly outnumbered and fearing an encounter on land, evacuated Athens and put all their hopes into a sea battle using their purpose designed navy as a final stratagem. BTW: the English word 'navy' is a borrowed Greek word: nauv-los. A nauv- archos is an Admiral. A nauv-tilia is a fleet and so on.
As you probably recall, the Persians force of 300,000 men and 1,200 ships went on to sack and occupy Athens with particular emphasis on desecrating the Greek Gods on the Holy Acropolis.
The Persian Navy in a support role, beached their ships at Phaliron, a mere 3 kilometers from the Acropolis (high-city) and visible from it. Incidentally, exactly where many of the the Greek navy's 350 triremes would have been had they not regrouped in nearby Salamis' Ambelakia Bay and the peninsulas of Kynossura and Pounta.