Jamie Mackie got the winner as QPR came from two goals down with 13 minutes left to beat Liverpool and move out of the relegation zone.
Sebastian Coates scored a spectacular volley and Dirk Kuyt prodded in a second to put the Reds ahead.
Shaun Derry gave QPR hope with a header before Reds old boy Djibril Cisse also nodded in to haul the home side level.
A Jose Enrique error left Mackie clear to slide in an injury-time shot under keeper Pepe Reina for the QPR winner.
QPR'S REMAINING FIXTURES
The victory was as vital for the home side as it was unlikely and helped move them two points clear of the drop zone, although third-from-bottom Bolton have a game in hand.
The loss left Liverpool's already faint hopes of a top-four finish in tatters, with the Reds a massive 12 points behind fourth-placed Tottenham after a fourth league defeat in five games.
The latest setback for the Reds was much of their own making in a turnaround which was as spectacular as the opener from centre-back Coates.
QPR seemed to be feeling the pressure of their precarious position early on, particularly after relegation rivals Blackburn had won on Tuesday.
QPR gave Liverpool too much respect - Hughes
The home side constantly gave the ball away and Liverpool had plenty of chances to take advantage as they swarmed all over their hosts.
Suarez left Nedum Onuoha trailing to burst clear on goal only to have his shot fended away by keeper Paddy Kenny before Derry blocked a Stewart Downing strike when the Reds winger seemed set to have a free shot on goal.
Kuyt had a great chance when he latched on to a Steven Gerrard corner to the far post but he was denied by another save from the overworked Kenny.
Liverpool's profligacy has been a hallmark of their season and, while it appeared to drain their belief, QPR took plenty of encouragement from weathering the early storm.
The home side eventually managed to get a view of the visitors' goal and Reds keeper Reina was a relieved figure when former Liverpool striker Cisse's 22-yard shot went just wide.
No explanation for defeat - Dalglish
QPR began to look comfortable but it proved a false sense of security. A Stewart Downing shot was cleared off the line by Bobby Zamora and, as the ball fell in the QPR box, Coates produced an acrobatic scissors kick to finally reward Liverpool's domination.
A Luis Suarez shot hit the post and Kenny saved from Downing before Kuyt stole in to pounce on the rebound and extend Liverpool's lead on his 200th Premier League outing.
There was little sign of the drama to come until Derry pulled one back with a 77th minute header from a corner to galvanise the home side.
Cisse nodded in another after 86 minutes and, when Reds left-back Enrique missed a clearance in added time, Mackie took full advantage to complete QPR's remarkable comeback.
Full Time The referee blows his whistle to end the game.
The assist for the goal came from Luke Young.
90:00 +0:57 Goal scored
Goal - Jamie Mackie - QPR 3 - 2 Liverpool Jamie Mackie finds the net with a goal from inside the penalty area to the bottom left corner of the goal. QPR 3-2 Liverpool.
Martin Skrtel challenges Akos Buzsaky unfairly and gives away a free kick. Free kick crossed by Luke Young.
Substitution Akos Buzsaky replaces Djibril Cisse.
Assist on the goal came from Taye Taiwo.
85:27 Goal scored
Goal - Djibril Cisse - QPR 2 - 2 Liverpool Djibril Cisse finds the back of the net with a headed goal from inside the six-yard box. QPR 2-2 Liverpool.
Samba Diakite concedes a free kick for a foul on Andy Carroll. Steven Gerrard produces a strike on goal direct from the free kick.
Free kick awarded for an unfair challenge on Martin Skrtel by Bobby Zamora. Jose Reina takes the direct free kick.
Indirect free kick taken by Patrick Kenny.
Substitution (Liverpool) makes a substitution, with Andy Carroll coming on for Luis Suarez.
The official flags Dirk Kuyt offside.
Stewart Downing takes the outswinging corner, Luke Young makes a clearance.
The official flags Jamie Mackie offside. Jose Reina takes the indirect free kick.
Short corner taken by Adel Taarabt from the left by-line.
Corner taken right-footed by Adel Taarabt,
Adel Taarabt provided the assist for the goal. Dirk Kuyt has an effort at goal from outside the area missing to the wide right of the goal.
76:11 Goal scored
Goal - Shaun Derry - QPR 1 - 2 Liverpool Shaun Derry finds the back of the net with a headed goal from close in. QPR 1-2 Liverpool.
Unfair challenge on Bobby Zamora by Martin Skrtel results in a free kick. Taye Taiwo produces a strike on goal direct from the free kick, Jay Spearing gets a block in.
The assistant referee flags for offside against Luis Suarez. Patrick Kenny restarts play with the free kick.
Assist by Stewart Downing.
71:24 Goal scored
Goal - Dirk Kuyt - QPR 0 - 2 Liverpool Goal scored by Dirk Kuyt from close in to the bottom left corner of the goal. QPR 0-2 Liverpool.
Luis Suarez has an effort at goal from deep inside the box hitting the post. Stewart Downing takes a shot. Patrick Kenny makes a save.
Stewart Downing takes a shot. Save by Patrick Kenny. Stewart Downing takes a short corner.
Luis Suarez fouled by Nedum Onuoha, the ref awards a free kick. Sanchez Jose Enrique restarts play with the free kick.
Steven Gerrard takes the outswinging corner, Jamie Mackie makes a clearance.
Outswinging corner taken right-footed by Adel Taarabt played to the near post, Martin Skrtel makes a clearance.
Corner taken right-footed by Adel Taarabt from the right by-line to the near post, clearance made by Jamie Carragher.
Patrick Kenny takes the free kick.
Substitution Jamie Mackie is brought on as a substitute for Joey Barton.
The offside flag is raised against Steven Gerrard.
Free kick awarded for a foul by Jay Spearing on Adel Taarabt. Samba Diakite takes the direct free kick.
Foul by Sanchez Jose Enrique on Djibril Cisse, free kick awarded. Joey Barton crosses the ball from the free kick right-footed from right channel, Steven Gerrard makes a clearance.
Stewart Downing takes a shot. Save by Patrick Kenny.
Stewart Downing takes a shot. Clearance by Luke Young.
Assist on the goal came from Stewart Downing.
53:34 Goal scored
Goal - Sebastian Coates - QPR 0 - 1 Liverpool Sebastian Coates gets on the score sheet with a goal from deep inside the penalty box high into the middle of the goal. QPR 0-1 Liverpool.
Stewart Downing takes a shot. Clearance made by Luke Young.
Outswinging corner taken from the right by-line by Steven Gerrard, Anton Ferdinand manages to make a clearance.
Anton Ferdinand concedes a free kick for a foul on Luis Suarez. Free kick taken by Steven Gerrard.
Short corner worked by Stewart Downing.
Corner taken left-footed by Stewart Downing from the right by-line to the near post, clearance made by Bobby Zamora.
Samba Diakite gives away a free kick for an unfair challenge on Luis Suarez. Luis Suarez restarts play with the free kick.
Free kick awarded for a foul by Joey Barton on Dirk Kuyt. Shot comes in from Steven Gerrard from the free kick, blocked by Nedum Onuoha.
Djibril Cisse takes a shot. Save by Jose Reina.
Substitution Armand Traore goes off and Taye Taiwo comes on.
Substitution Jordan Henderson joins the action as a substitute, replacing Charlie Adam.
The match restarts for the second half.
45:00 +2:53 Half time
Half Time It is the end of the first-half.
Corner taken by Joey Barton from the right by-line.
Samba Diakite takes a shot.
Charlie Adam gives away a free kick for an unfair challenge on Samba Diakite. Anton Ferdinand takes the free kick.
Foul by Charlie Adam on Joey Barton, free kick awarded. Joey Barton takes the free kick.
Djibril Cisse takes a shot. Sebastian Coates gets a block in.
Substitution Sebastian Coates is brought on as a substitute for Martin Kelly.
Long range shot by Joey Barton goes wide right of the goal.
Djibril Cisse has an effort at goal from outside the area missing to the wide right of the target.
Inswinging corner taken right-footed by Joey Barton, Charlie Adam makes a clearance. Outswinging corner taken right-footed by Joey Barton played to the near post, clearance made by Steven Gerrard.
Luis Suarez has an effort at goal from just outside the box which goes wide of the right-hand upright.
Charlie Adam takes the outswinging corner, Header from deep inside the area by Martin Skrtel goes over the bar.
Outswinging corner taken right-footed by Steven Gerrard from the right by-line to the near post, Bobby Zamora makes a clearance.
Stewart Downing takes a shot. Blocked by Samba Diakite.
Stewart Downing decides to take a short corner.
Charlie Adam fouled by Bobby Zamora, the ref awards a free kick. Direct free kick taken by Jay Spearing.
The assistant referee flags for offside against Luis Suarez. Patrick Kenny takes the free kick.
Djibril Cisse produces a right-footed shot from outside the box and misses left.
Short corner taken by Stewart Downing from the right by-line.
Corner taken by Steven Gerrard from the right by-line played to the near post, Header from close in by Luis Suarez misses to the left of the goal. Dirk Kuyt takes a shot. Blocked by Luke Young.
Corner taken by Steven Gerrard from the right by-line played to the near post, clearance made by Luke Young.
Inswinging corner taken right-footed by Steven Gerrard from the left by-line, Armand Traore manages to make a clearance. Inswinging corner taken by Stewart Downing, Martin Skrtel takes a shot. Anton Ferdinand gets a block in.
Free kick awarded for a foul by Joey Barton on Sanchez Jose Enrique. Sanchez Jose Enrique takes the direct free kick.
Corner taken right-footed by Steven Gerrard from the left by-line, clearance made by Nedum Onuoha.
Corner taken by Stewart Downing from the right by-line, clearance by Luke Young.
Luis Suarez takes a shot. Patrick Kenny makes a save. Luis Suarez takes a shot. Save by Patrick Kenny. Corner taken by Steven Gerrard from the left by-line, Armand Traore manages to make a clearance.
Jay Spearing is adjudged to have handled the ball. Free kick taken by Joey Barton.
The match gets underway.
Live text and data provided by The Press Association
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.