After a open period of frustration for the Blues, the visitors took a shock lead via Laurent Depoitre's 50th-minute goal following an error by Willy Caballero, which allowed the Belgium to control and clip over the Argentine.
Marcos Alonso leveled just after the hour mark following a deflected shot - off the Spaniard's face - which saw the calvary charge in West London.
David Wagner's men held on however, including a sensational stop from 'keeper Jonas Lössl, as the final whistle was met was rapturous scenes from the away supporters and who celebrated avoiding immediate relegation from the top-flight.
With the hosts needing a win to keep up any hopes of catching Tottenham Hotspur into fourth spot, Chelsea sought an opening goal in their final home game of the season, but were met by a determined Huddersfield outfit still buoyed from Sunday afternoon's goalless draw against the champions Manchester City.
The hosts were still however guilty of spurning a number of gilt-edged chances to open the scoring.
Willian had a shot go narrowly wide of Jonas Lossl's boughs, before Antonio Rudiger protracted to miss from a yard out at the back post following Cesar Azpilicueta's flick on from a corner. The German could also have notched when found unmarked from a set piece again, but failed to make contact from a re-directed corner by inches.
The first-half was again a story of frustration for Álvaro Morata, who drew a blank after being Olivier Giroud was rested to the bench by Antonio Conte.
Morata found space on two key occasions. First after a searching through ball found the forward in the area, but his effort could was straight at Lossl, after striking on the volley, off-balance.
The Spaniard should have done better however, when put through clean on goal, but as he evaded Danishman Lossl veered wide and left with an acute angle could only shy across the goalmouth.
Terriers stun hosts
Spurred on by the opening period disappointment, Chelsea came out of the traps flying, but were caught out by a rare sojourn forward by the visitors.
After a hopeful ball forward, Depoitre found a yard of space and as Blues keeper Caballero came out thwart the Belgian, collided with the striker and was felled. As protestations flew from the hosts' defence, referee Lee Mason waved play on leaving Depoitre to loft the ball into the empty net and give Huddersfield a shock lead.
Chelsea were level rather fortuitously within 12 minutes however, as a clearance from the area after an Azpilicueta cross hit Alonso in the face as the ball ricocheted into the net to level the scores.
Visitors cling on for safety
The equalizer saw Giroud and Eden Hazard thrown on and resulted in a frenetic final 20 minutes in West London. As ball after ball was sent into the area from Willian, Hazard and Azpilicueta the tireless Terrier defends were like lions to every ball to clear the danger.
It was however a remarkable piece of agility that kept the scores level late on. Following a melee in the 18-yard-box, Andreas Christensen rose highest above a creaking defence to head on goal and was denied only by a fingertip save - again by Lossl - onto the post as the ball trickled away from the goal.
As the official's board for six minutes additional time went up, Wagner's men steeled themselves for one final effort. Chelsea however failed to create any meaningful openings to the dismay of the home supporters, as the final whistle saw raucous scenes in the away end and Huddersfield players and stuff celebrated wildly with the visiting fans, having sealed their Premier League safety - some would say against the odds.
The result also leaves Chelsea needing a miraculous turn of events to finish fourth after Spurs' win against Newcastle United, with Swansea City now effectively relegated back down the Championship.