Zaliukas (left) lashes the ball into the net for Hearts' first
Hearts extended their winning run to five matches with victory over Rangers at Tynecastle.
Marius Zaliukas fired Hearts in front from close range shortly before Laryea Kingston headed a second on 23 minutes.
But Christos Karipidis' own goal brought Rangers back into the match three minutes later.
Lee Wallace was sent off for receiving a second booking with 14 minutes left but Rangers were unable to make their one-man advantage count.
The home side threatened as early as the opening minute with Andrew Driver's right-foot shot claimed by Rangers goalkeeper Allan McGregor.
Rangers had the chance to test Hearts goalkeeper Jamie MacDonald in the 15th minute when Robbie Neilson was penalised on the edge of the box for handball.
But Boyd's shot from Pedro Mendes' lay-off was wildly off target.
Hearts took the lead after 20 minutes when Rangers failed to deal with Bruno Aguiar's dangerous free-kick.
Kingston celebrates after putting Hearts two goals up
McGregor saved well from Christophe Berra's powerful header and Zaliukas hammered home the loose ball as Madjid Bougherra struggled to clear.
Bougherra was booked for a foul on Driver on the left flank and Aguiar's prowess from set pieces again proved crucial.
Berra's header from the midfielder's cross was palmed out by McGregor and Kingston headed in the rebound on his return from injury.
Rangers pulled one back when Karipidis' downward header from Adam's free-kick bounced over the Hearts goal-line via the crossbar.
Whittaker's mistake five minutes before half-time almost gifted Hearts a third goal as Kingston played one-two with Aguiar before seeing his shot saved.
Boyd and Whittaker were both cautioned as an eventful first half drew to a close.
Mendes' ambitious volley from the right-hand side was deflected over the bar by Berra's head at the start of the second but a goal-kick was awarded by the officials.
Rangers winger Chris Burke then made his return from a long-term ankle injury as a substitute in place of Adam.
Kingston's run and shot in the 58th minute drew a save from McGregor before Boyd headed over at the other end from David Weir's cross.
Hearts were reduced to ten men when Wallace picked up a second yellow card for a late challenge on Burke.
Boyd hooked over from Kyle Lafferty's knock down before Hearts substitute David Obua headed wide from a corner.
Rangers pressed for a late leveller but were unable to trouble MacDonald's goal with Kirk Broadfoot firing wide in injury-time.
Hearts manager Csaba Laszlo:
"I believe in my work and I believe in my team.
"I know at the moment it's important to collect the points and if you can win against Rangers, especially at home, you must win and you must take the points.
"At the end of the season we'll look at which position we are. But if you beat Rangers, you take only three points. If you beat Celtic, you take only three points.
"The other teams can believe Rangers and Celtic are not so good."
Rangers manager Walter Smith:
"I don't think Hearts had many opportunities in terms of attempts at goal or cutting us open but it was more of the set-play aspect that we didn't handle and it cost us two goals.
"We proceeded to give away far too many free-kicks in the first 20-25 minutes of the game.
"After that, for the last hour of the game, it was played almost entirely in Hearts' half, but we weren't good enough to create opportunities.
"There's been these lapses that have caused us these problems as much as anything else."
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.