After the outbreak of World War II, she went to patrol the waters around South America, where she sunk the German merchantman Olinda and intercepted the German merchantman Carl Fritzen and the passenger ship Ussukuma. These two ships sunk themselves to prevent the ships from being used by the Royal Navy.
During the hunt for the Admiral Graf Spee, HMS Ajax was Commodore Henry Harwood's flagship. Although the Ajax was hit seven times by the Admiral Graf Spee, the ship, along with HMS Achilles and HMS Exeter, managed to damage the Admiral Graf Spee and put her to flight.
The Admiral Graf Spee sailed into the neutral port of Montevideo in Uruguay, but was only allowed to stay there for 72 hours. The HMS Ajax and the HMS Achilles were lurking outside the port and Captain Hans Langsdorff decided to sink his ship just outside Montevideo.
After the Admiral Graf Spee was sunk, the Ajax returned to England to dock until July 1940. After that, HMS Ajax was stationed in the Mediterranean.