Hearts added to Jim Jefferies' misery as their win left their former manager's Dunfermline Athletic side deeper in relegation trouble.
The Pars had the better of the first half, although Alex Keddie had to clear a goalbound Gary Glen effort clear from in front of goal just before half time.
But Glen fired in off the post after 49 minutes and Keddie deflected into his own net four minutes later.
Marius Zaliukas deflected into his own net with five minutes remaining.
But it was all too late for Dunfermline to stage a comeback that would rescue a point never mind record a first home win of the season.
Jefferies could not get the better of the man who succeeded him, Paulo Sergio
And the defeat leaves the side now led by former Hearts boss Jefferies six points behind second-bottom Hibernian, who face Motherwell on Sunday.
Paul Willis, David Graham and Kyle Hutton had started for Dunfermline, with Kevin Rutkiewicz and Martin Hardie missing through injury and Joe Cardle dropped to the bench.
With Andy Webster injured and Craig Beattie not risked ahead of next weekend's Scottish Cup semi-final, Scott Robinson and Glen came in for Hearts.
The first real chance came from Dunfermline via two former Hearts players after 18 minutes.
Austin McCann worked his way to the bye-line and his cross to the back post was headed wide under pressure by Andy Kirk.
It was Dunfermline doing most of the pressing early on and, after a flurry of corners came to nothing, Kirk sent a snap shot on to the roof of the net from 18 yards.
However, Hearts ought to have taken the lead shortly before the break when Gary Glen intercepted a wayward backheader from McCann, but Keddie managed to clear the striker's weak attempt to pass the ball round goalkeeper Chris Smith.
Jamie Hamill fired straight at Smith following the corner.
After the break, Hearts continued where they left off and Smith had to produce a breathtaking, one-handed save following a thundering close-range volley from Rudi Skacel.
However, Smith was beaten moments later when the ball fell to Glen following a Danny Grainger cross and the striker's half-hit shot rolled in off the far post.
Keddie went from hero to zero within a matter of seconds when the big defender cleared a Ryan McGowan off the Pars goalline.
However, when the ball was knocked back into the six yard box by Zaliukas, the defender diverted the ball into the net under pressure from Darren Barr.
That seemed to have killed off Dunfermline until Zaliukas diverted in a cross from Cardle.
The Pars suddenly sniffed a chance of a comeback, but the substitute winger squandered their best opportunity, firing a free-kick well over the crossbar.
Dunfermline manager Jim Jefferies:
"We had been the better team in the first half.
"The shape was good and Hearts never caused us any problems. As a manager you know what's coming. So you say to them at half-time, 'I know what's going to happen, they're going to go in, get a kick up the backside and be told that it wasn't good enough. And if there's anything about them they'll step up. And you'll have to deal with that'.
"The players were told that, deal with it by concentrating harder and being braver and we got none of those things, the goals were too easy for me.
"It's something I've been told that's happened often this season. It's something they've got to learn from and they haven't.
"Other teams, especially teams in the top half, are going to come here and expect to win comfortably. So in the first half if you outplay them, they're going to be told off at half time and you have to be prepared."
Hearts coach Gary Locke:
"We felt at half-time that we didn't do ourselves justice in the first half.
"(manager) Paulo (Sergio) felt they weren't moving the ball quickly enough and they weren't showing for the ball as well as they have in recent weeks.
"In the second half once we got the ball down and started to pass it a bit quicker and move a bit better then I felt we were in control of the game and we're delighted with the three points."
- 20 Smith
- 03 McCann
- 06 Keddie
- 15 Dowie
- 26 McMillan
- 02 Kerr Booked (McDougall - 63' )
- 04 Mason
- 22 Willis (Buchanan - 75' )
- 24 Hutton
- 10 Kirk (Cardle - 63' )
- 11 Graham
- 27 Fernandez
- 39 Young
- 07 Cardle
- 23 Thomson
- 12 McDougall
- 19 Buchanan
Heart of Midlothian
- 30 MacDonald
- 03 Grainger
- 05 Barr
- 17 McGowan Booked
- 26 Zaliukas
- 02 Hamill
- 08 Black Booked (Prychynenko - 89' )
- 11 Driver (Novikovas - 83' )
- 19 Skacel
- 23 Glen (Santana - 72' )
- 27 Robinson
- 28 Ridgers
- 07 Santana
- 35 Prychynenko
- 42 Holt
- 18 Novikovas
- 22 Smith
- 38 Morton