Jose Mourinho’s side went ahead after 16 minutes as Fernando Torres followed up to slot home after Willian’s shot had cannoned back off the post.
However, Palace responded and the in-form Marouane Chamakh volleyed home on the half-hour.
The winner came just five minutes later and it was a fine finish from Ramires, who fired home from the edge of the box.
The three points take Chelsea into second place – now just two points adrift of leaders Arsenal.
Those expecting Chelsea to romp away with the points and fire a warning to both Arsenal and Manchester City were mistaken and the hosts were indebted to Petr Cech when the goalkeeper saved from substitute Stuart O’Keefe.
Despite the shaking foundations, still Stamford Bridge remains a fortress, as Chelsea extended their unbeaten home run in the league to 16 games and Mourinho’s home league record to 68 undefeated.
Palace harassed and harangued Chelsea early on, so much so that the Blues could not string a meaningful period of possession together.
When they did the warning was there for the Eagles, as Julian Speroni saved Ramires’ volley.
Moments later, the goalkeeper turned a stinging shot from another Brazilian on to the post, but Willian’s effort rebounded for Torres to pounce and tuck in.
Branislav Ivanovic and Michael Essien shot off target as Chelsea continued to pile the pressure on Palace, who were forced into an early change when Kagisho Dikgacoi was replaced by O’Keefe.
Cameron Jerome forced Cech into a save as the Chelsea defense backed off before the visitors equalized through former Arsenal striker Chamakh. David Luiz rushed out from defense towards Jason Puncheon, who found Joel Ward on the left.
Chamakh found space as marker John Terry lost his man and the Moroccan clipped the ball in beyond Cech.
Palace’s joy did not last for long as Willian fed Hazard, who cut in dangerously before teeing up Ramires on the edge of the area.
The midfielder took one touch before curling a sumptuous right-footed effort into the top corner.
Hazard tried to create another when he evaded Adrian Mariappa, ran along the byline and set up Willian, but his deflected shot was easily saved, causing Mourinho to kick a bag in his technical area in frustration.
If anyone expected Chelsea to cruise in the second half, Palace had other ideas.
Puncheon had a shot saved on the counter attack after escaping the attentions of Cesar Azpilicueta before his dangerous cross from a free-kick saw Damien Delaney head straight at Cech.
Delaney made a well-timed tackle to deny Ivanovic in the area before Mourinho turned to Oscar, who replaced Mata.
The Brazilian could not spark Chelsea into action and instead the Blues had to rely on Cech to stay in front after fine work by Jerome found O’Keefe, whose first shot was excellently saved and his second blocked by Ivanovic before the ball was scrambled clear.
Delaney headed wide from a corner moments later after escaping the attentions of Chelsea’s defense, who appeared vulnerable.
Ramires then fluffed a golden opportunity for a third. Oscar won the ball from two Palace defenders, but Ramires could not decide whether to shoot or pass to three of his waiting team-mates.
Speroni made three saves in quick succession to deny substitutes Andre Schurrle and Demba Ba, as well as Ramires, but in the end the failure to find a third did not prove costly as Chelsea triumphed.