Thapelo Mkhatshwa put the visitors ahead, but an inspired performance by Abia Nale helped Ajax turn the scoreline around, before a dramatic finish with late goals by Sedate Ouro-Akoriko and Khama Billiat.
Ajax came into the game desperate for a turnaround of fortunes, as they languish in the relegation zone.
And Steve Komphela’s side are experiencing a similar run of bad form, as their chances of a top four finish have been crushed by a four-match winless run.
Jan Versleijen blasted his players after their 3-1 loss to Mamelodi Sundowns midweek and he opted to completely reshuffle his team, with five changes to the starting line-up.
Lebogang Manyama, Abia Nale and Wanderson formed part of a new attacking trio, with Khama Billiat dropped and Mabhuti Khenyeza suspended.
But it was Lance Davids who struck the first effort at goal, although his attempt was wide.
The attacking force of Stars has been put under heavy scrutiny throughout the season, and it was a trademark error by Ajax’s defence that led to the first goal, after they failed to close down Mkhatshwa who struck a low effort to beat Sander Westerveld at his near post.
12 minutes later Nale spotted Manyama unmarked at the far post and he supplied a great cross that allowed his teammate to complete the simple tap-in.
Six minutes before the break and the visitors were dealt another blow when Moeketsi Mvula had to replace Fikru Lemessa owing to injury.
With the match delicately poised, the Urban Warriors knew that they needed to come out firing with all cylinders in the second half, and they did so.
Nale converted a long ball into the box to make it 2-1, before Matthew Booth made amends for his bad positioning on the earlier goal with a perfectly timed intervention on Mvula’s cross to flick the ball over the crossbar, for the save of the day.
Khama Billiat came on for the cramping Nale and managed to lob the ball over Tshepo Motsoeneng put Ajax up 3-1.
Ea Lla Koto responded three minutes later when Ouro-Akoriko rattled the back of the net with a powerful strike from range, but a few minutes later Billiat and Manyama combined again to put the win beyond doubt.