By Alex Livie
Last Updated: 01/01/70 1:00am
Steven Milne gave the visitors an early lead, but Hearts battled back in the second half and levelled through Paul Hartley on 52.
Dundee had no answer to Hearts' pressure and were undone on the hour when Steven Pressley converted from the penalty spot.
The comeback was complete when Joe Hamill netted on 67.
Kilmarnock got the better of their tussle with fellow strugglers Aberdeen, running out 3-1 winners at Rugby Park.
Second bottom Kilmarnock started the day level on points with The Dons but were buoyed by Craig Dargo's early effort.
Bryan Prunty swiftly levelled for Aberdeen, but Kris Boyd's brace on 28 and 76 handed Killie a valuable three points.
Jason Scotland's effort on 66 minutes handed Dundee United a 1-0 win over Motherwell.
Livingston and Dunfermline played out a 0-0 draw, while basement boys Partick Thistle had to settle for a point from their home game with Hibernian.
Colin Murdock had Hibs in front on 68, but Andy Thomson's penalty two minutes later snatched a point for Partick.