Zeefuik’s powerful low strike from 12 yards in the 85th minute was a little harsh on the hosts who had held their own in terms of chances created if not on possession.
Queen of the South, who have not beaten the Jambos since 1964, opened the scoring midway through the first half through Daniel Carmichael who fired home at the far post after collecting Lewis Kidd’s drilled cross.
The lead lasted eight minutes before Billy King levelled matters from inside the box as he found the left-hand corner of the net from Callum Paterson’s assist.
And that was the way it remained until five minutes from time, although both sides had opportunities to take the lead during an end-to-end second half.
King and Danny Wilson went close for the visitors while Andy Dowie and Mark Durnan failed with headers for the Doonhamers shortly before Zeefuik snatched three points for the Edinburgh giants when he met Adam Eckersley’s cross to score with a deflected shot.
Queen of the South goalkeeper Alex Clark came up for a corner in injury time and was not too far away with a header but the Jambos held on.
Scottish Championship leaders Hearts remain unbeaten on the road this season while Queen of the South are five points adrift of third-placed Rangers, who also have a couple of games in hand in the battle for a play-off place.