Goalkeeper Cammy Bell was Kilmarnock's hero as he saved a Matt Lockwood penalty to deny Dundee a top-flight scalp in the Scottish Cup fourth round.
Steven Milne had the ball in the net for the First Division side early on but was correctly ruled offside.
Manuel Pascali headed Killie ahead from a 32nd-minute corner.
But Milne poked in the equaliser a minute after the break before Lockwood's weak penalty and fine saves from Bell and counterpart Rab Douglas.
Dundee manager Barry Smith, whose side had only lost once in their last eight game, had adopted a more defensive formation than normal.
However, despite having only one out and out striker, his players quickly put Kilmarnock under pressure playing down the Dens Park slope.
Gary Irvine failed to get enough purchase on an early toe-poke straight at Bell after the full-back burst into the Kilmarnock box.
Veteran former Scotland midfielder Gavin Rae was thwarted by a Pascali block a few yards from goal after his defensive partner Mohamed Sissoko mis-timed his attempt to clear.
Kilmarnock at last broke out of their own half and Dean Sheils was unable to direct the ball on target with a volley from an awkward height 12 yards out.
Milne found the net after 15 minutes only to have his celebrations cut short when referee Stevie O'Reilly consulted assistant Charlie Smith.
The striker initially looked onside as he gathered Ryan Conroy's through ball before rounding Bell, but television replays showed that it had reached Milne via a flick from Ross Chisholm.
Although there were no Kilmarnock protests moments later, Heffernan looked to have more of a case for being onside when the flag went up when the striker was through on goal.
Kilmarnock had worked their way into the game, but it was still against the run of play when Pascali evaded his marker to beat a flapping Douglas to Shiels' corner floated to the front post.
Heffernan set up Shiels for a shot on the turn that slipped just wide of the far post from 14 yards, while Rae ought to have done better than drive a couple of feet over after finding himself in the clear just outside the penalty box.
There were to be no doubts about the Conroy-Milne combination a minute into the second half when Rae set the winger off towards the bye-line and his low cross was turned in by the striker's outstretched leg.
Douglas rolled back the years to superbly turn over the crossbar a powerful drive from Garry Hay before Dundee squandered a golden opportunity to take the lead when Sissoko pushed Conroy in the back as they jostled for a Jamie McCluskey cross.
However, Bell got down to hold Lockwood's poorly taken penalty kick.
Pascali sent a header just wide and had another effort saved by Douglas after a deflection off Rae.
The Dundee goalkeeper was upstaged by his opposite number when Bell produced a superb double save, blocking at the feet of Milne then stretching one-handed to turn wide a Conroy header when the ball was played back into the box.
Sorry, we were unable to load match stats, please try again.
Live Text Commentary
Full Time The final whistle goes and the game is over.89:07
Free kick awarded for a foul by Paul Heffernan on Neil McGregor. Robert Douglas takes the direct free kick.86:21
Paul Heffernan is flagged offside by the assistant referee. Robert Douglas takes the indirect free kick.85:02
Ross Chisholm concedes a free kick for a foul on Dean Shiels. Liam Kelly restarts play with the free kick. Shot from long range by Liam Kelly goes over the bar.81:39
Foul by Ross Chisholm on Danny Racchi, free kick awarded. Garry Hay takes the free kick.79:31
Paul Heffernan takes a shot. Craig McKeown gets a block in. Corner from right by-line taken by Dean Shiels.78:17
Steven Milne takes a shot. Robert Douglas makes a save. Ryan Conroy takes a shot. Save by Cameron Bell. Corner taken right-footed by Ryan Conroy, save by Cameron Bell.76:25
Dean Shiels takes the outswinging corner, Liam Kelly takes a shot. Robert Douglas makes a save.74:56
William Gros concedes a free kick for a foul on Ross Chisholm. Free kick taken by Craig McKeown.73:29 Substitution
Substitution Jamie McCluskey leaves the field to be replaced by Jake Hyde.72:31
Stephen O'Donnell challenges Liam Kelly unfairly and gives away a free kick. Cameron Bell restarts play with the free kick.72:04
Inswinging corner taken from the right by-line by Ryan Conroy, clearance made by James Fowler.70:37
Shot from long distance by Dean Shiels misses to the right of the goal.67:02
Corner taken right-footed by Dean Shiels from the right by-line, Close range header by Manuel Pascali misses to the right of the target.66:31
Inswinging corner taken right-footed by Dean Shiels, Stephen O'Donnell makes a clearance.63:53 Penalty
Penalty taken by Matthew Lockwood saved by Cameron Bell. Dundee 1-1 Kilmarnock.63:20 Booking
Booking Booking for Mohamadou Sissoko for unsporting behaviour.62:43
Mohamadou Sissoko gives away a Penalty for an unfair challenge on Jamie McCluskey.61:58
Outswinging corner taken from the left by-line by Ryan Conroy.59:02
Free kick awarded for an unfair challenge on Danny Racchi by Craig McKeown. Strike on goal comes in from Garry Hay from the free kick.
Booking Craig McKeown goes into the referee's book for unsporting behaviour.56:16 Substitution
Substitution William Gros is brought on as a substitute for James Dayton.54:18
Danny Racchi takes a shot. Neil McGregor gets a block in.52:10
James Dayton fouled by Gary Irvine, the ref awards a free kick. The free kick is delivered right-footed by Dean Shiels from right channel, Cameron Bell makes a save.50:21
Dean Shiels takes the inswinging corner, Headed from the edge of the area by Manuel Pascali goes wide of the left-hand post.49:01
Corner taken by Dean Shiels, Neil McGregor manages to make a clearance. Garry Hay takes a shot. Robert Douglas makes a save.48:17
Jamie McCluskey takes a shot from deep inside the box clearing the bar.45:24
Assist by Ryan Conroy.45:24 Goal scored
Goal! - Steven Milne - Dundee 1 - 1 Kilmarnock Steven Milne finds the net with a goal from close in to the bottom right corner of the goal. Dundee 1-1 Kilmarnock.45:18
Ryan Conroy sends in a cross,45:01
The referee blows his whistle to start the second half.45:00 +0:03 Half time
Half Time The match has reached half-time.42:18
Effort from just outside the area by Gavin Rae goes over the target.38:02
Foul by Gavin Rae on Manuel Pascali, free kick awarded. Liam Kelly restarts play with the free kick.36:55
Craig McKeown produces a cross.34:51
Dean Shiels produces a right-footed shot from deep inside the penalty box which goes wide of the left-hand post.33:45
The referee penalises Danny Racchi for handball. Ryan Conroy delivers the ball from the free kick left-footed from left channel, clearance made by Paul Heffernan.31:26
Assist by Dean Shiels.31:26 Goal scored
Goal! - Manuel Pascali - Dundee 0 - 1 Kilmarnock Manuel Pascali grabs a headed goal from close range. Dundee 0-1 Kilmarnock.31:03
Inswinging corner taken right-footed by Dean Shiels from the left by-line,26:28
Free kick awarded for a foul by Danny Racchi on Neil McGregor. Jamie McCluskey fires a strike on goal direct from the free kick.24:52
The official flags Paul Heffernan offside. Free kick taken by Robert Douglas.24:05
Effort from outside the penalty box by Paul Heffernan goes wide left of the target.21:31
The referee blows for offside against Paul Heffernan. Robert Douglas restarts play with the free kick.17:51
Ross Chisholm challenges Dean Shiels unfairly and gives away a free kick. Mohamadou Sissoko takes the direct free kick.16:50
Free kick awarded for a foul by Craig McKeown on James Dayton. James Dayton takes the direct free kick.13:45
Free kick awarded for an unfair challenge on Gary Irvine by Garry Hay. Ryan Conroy produces a strike on goal direct from the free kick, save by Cameron Bell.12:07
Dean Shiels produces a left-footed shot from deep inside the area which goes wide of the left-hand post.9:52
Outswinging corner taken left-footed by Ryan Conroy, Manuel Pascali makes a clearance.8:49
Danny Racchi concedes a free kick for a foul on Jamie McCluskey. Stephen O'Donnell restarts play with the free kick.8:12
Ross Chisholm takes a shot. Cameron Bell makes a save.7:10
Gary Irvine takes a shot. Save by Cameron Bell.4:49
Outswinging corner taken by Dean Shiels from the right by-line.0:49
Long range shot by Stephen O'Donnell goes wide right of the net.0:00
The match begins.
Live data and text provided by our data suppliers