McLeod broke the deadlock in the 63rd minute and added a second from the penalty spot, before non-league Farsley had Simeon Bambrook and Roy Stammer sent off.
The Conference North minnows dominated the first half and Bambrook, Gareth Grant and Stammer all tested Dons goalkeeper Adolfo Baines-Pilart from long range inside the first ten minutes.
The Dons struggled to settle into their stride but Paul Mitchell should have put them ahead on the counter-attack when he fired straight at Celts keeper Paul Cuss from ten yards.
Bambrook's angled drive was saved by Dons keeper Baines-Pilart at his near post, before McLeod's shot was heroically cleared off the line by Ryan Crossley midway through the first half.
Farsley substitute Craig Midgley - on for the injured Andy Watson -- was unlucky when his near-post header from Bambrook's cross flew just wide.
But the Dons continued to threaten on the break and McLeod's seven-yard glancing header from Jon-Paul McGovern's cross drifted inches wide of the far post before Gareth Edds' rasping 25-yard drive was saved well by Cuss in the 41st minute.
Milton Keynes upped their game after the interval and Edds' low 20-yard drive struck the foot of the post ten minutes after the restart.
Yet the Dons had to rely on a superb save from Baines-Pilart to keep out Bambrook's fierce deflected 22-yard strike before McLeod gave them a 63rd minute lead.
The deadlock was finally broken when Edds lifted the ball through to McLeod, who volleyed past Cuss from eight yards.
And McLeod took his season's goal tally to 11 when he doubled the Dons' lead from the penalty spot in the 76th minute.
McLeod stepped up to smash the ball straight down the middle after Stammer had tripped Mitchell just inside the box.
Farsley keeper Cuss produced a magnificent save to keep out Dean Lewington's swerving 25-yard free-kick, before Bambrook was shown a straight red card for cynically bringing down Dons substitute Scott Taylor in the 79th minute and Stammer picked up his second booking for a trip on substitute John Hastings three minutes from the end.