Killie outclassed the Irn-Bru First Division team in a one-sided third-round tie.
Gary Harkins opened the scoring after just two minutes, his deflected shot nestling in the corner of the net.
From that moment onwards Heffernan was to make the headlines. The Queens defence were patently unable to cope with his movement as a ruthlessly clinical display took his tally for the season to a remarkable eight goals in six games.
Substitute Ben Hutchinson added some deserved gloss to the score, curling a delightful left-footed effort past a shell-shocked Lee Robinson. The clear gulf between the sides certainly was not helped as Kevin Smith was given his marching orders in the first half for swinging an arm at Leon Panikvar.
A strong Killie side showed just two changes from the team which drew 2-2 at Pittodrie at the weekend. Mohamadou Sissoko made his first start since reprising his loan from Udinese, with the towering Frenchman replacing Garry Hay. Gary Fisher also made his first start of the season in place of James Dayton.
And Kilmarnock claimed the lead within minutes. Queens failed to deal with a simple pass towards Harkins, allowing the former Dundee man to collect on the edge of the area. His drive took a wicked deflection off the boot of Craig Reid and looped into the net.
Minutes later a Heffernan shot from the edge of the box was palmed away by Robinson before Liam Kelly blasted the rebound well over.
The tricky Dean Shiels was next to threaten, powering into the box and forcing a good save from Robinson from a tight angle.
With Queens struggling to contain the home side with eleven men, Smith's next involvement was not advisable. The towering striker swung an arm at Panikvar, naturally prompting Stevie O'Reilly to wave a red card at him.
Heffernan was quick to make the most of the numerical advantage. The elusive Shiels found a pocket of space on the right flank to whip in a cross, allowing the 29-year old to stoop at the near post to score.
A Nicky Clark free-kick, inches wide, was a promising start to the second period for Queens, but not a sign of things to come. Indeed, on the hour-mark
Heffernan was on-hand to out-muscle the Doonhamers' defence and rattle home an emphatic finish from eight yards.
And 10 minutes later the prolific hit-man had his hat-trick. He broke a tired offside trap to race on to a through-ball before showing real class to calmly lob the ball over Robinson into the net.
If anything, their dominance was creating some profligacy in Kilmarnock's play as several chances were passed up, but Hutchinson did make it five with 15 minutes to play. The former Celtic man danced into the box with a couple of step-overs and curled a wonderful shot past Robinson to cap an impressive, albeit comfortable, evening from the hosts.