Stephen Kelly struck two first-half goals as second-placed Livingston swept aside fellow Scottish Championship high-fliers Ayr 5-0.
Kelly grabbed an early opener when he slotted home from the edge of the penalty area after six minutes and Robbie Muirhead made it two from the penalty spot after a foul on Cristian Montano.
Ayr capitulated again moments before the interval, Kelly latching on to a long throw from Muirhead and steering past Harry Stone to effectively settle the tie.
Montano helped himself to the fourth and substitute Reece McAlear lashed home a stunning long-range volley as Livi moved within three points of leaders Falkirk and eight ahead of their opponents.