Axel Disasi had a stoppage-time winner disallowed but Chelsea came from two goals down to dent Aston Villa's top-four hopes in Birmingham.
Disasi thought he had sealed victory after he nodded home Benoit Badiashile's cross but the video assistant referee (VAR) recommended an on-field review and referee Craig Pawson decided the latter had barged a Villa defender before the cross.
Chelsea's players were incensed and crowded Pawson at the full-time whistle, while manager Mauricio Pochettino had a passionate discussion with Villa defender Ezri Konsa.
Villa, whose top-four hopes are now not in their hands as a result of the dropped points, had taken an early lead after John McGinn's miscued effort deflected off Chelsea left-back Marc Cucurella and into the bottom corner.
The visitors responded well with Nicolas Jackson having an effort disallowed by the video assistant referee for offside, before the Senegal international planted a header against the base of the post.
Morgan Rogers doubled the home side's lead after finding space on the left and tucking the ball into the near post through the legs of Trevoh Chalobah.
Chelsea found a route back into the game after catching Villa in possession high up the pitch, with Noni Madueke sliding a clever finish into the far corner.
The visitors pressed for an equaliser without creating too many opportunities, until Gallagher worked a shooting opportunity on his left foot and curled into the top corner from the edge of the area.
Both sides had chances to win the game before the disallowed goal, with Ollie Watkins slicing a cutback over the bar and Cole Palmer having a shot saved when dribbling through one-on-one.
Unai Emery's side are seven points clear of fifth-placed Tottenham, but Ange Postecoglu's side have three games in hand, starting with Sunday's north London derby against Arsenal.
There was further concern for Villa too, with goalkeeper Emi Martinez withdrawn at half-time after appearing to struggle with a thigh injury in the first period, and any period of absence could damage them with their Europa Conference League semi-final this week.
BBC