Craig Moore’s first-half strike may have come completely against the run of play but it was enough to register only a second victory in eight matches for the Honest Men and consign Dunfermline to a fourth consecutive defeat.
The visitors have taken time to adjust to the departure of manager Ian McCall to Partick Thistle but still leapfrogged Dundee into third spot and moved to within four points of Inverness Caley Thistle in second.
“It was a bit of a different style today,” said Ayr player-manager Mark Kerr. “We didn’t want to be too open and try to play too many intricate passes in the first half. We’ve been stung by that in the past few weeks and teams have started to find us out.
“It was maybe ugly to watch at times. But we need to learn we can’t just play the same way. Teams are saying Ayr United are great, one of the best teams in the league – but it doesn’t matter if you’re not taking points.”
Dunfermline looked determined to reverse their recent ailing fortunes. They poured men forward, peppered the Ayr goal with shots and bossed possession.
But the decisive moment came seven minutes from the break. Ayr’s Alan Forrest drilled in a shot from the left that was heading wide before Moore’s outstretched leg diverted the ball into the bottom corner.
“I’ve got faith we can turn it round,” said Pars boss Stevie Crawford of the string of defeats.