Joey Barton scored on his return to help earn QPR a two-point cushion above the relegation zone as Swansea slumped to a fourth straight defeat.
The captain marked his recall with a sublime finish after Swansea failed to clear Adel Taarabt's free kick.
Swansea were poor and Jamie Mackie added a second for QPR with an effort which deflected off Angel Rangel before Akos Buzsaky made it 3-0 from 25 yards.
Wayne Routledge had the visitors' best chance but blazed over from 12 yards.
Barton had deliberately been left out of the previous game against Manchester United, a 2-0 defeat, to avoid picking up a suspension.
But the QPR captain, who was criticised by his own supporters recently, was inspirational from start to finish on this occasion.
And QPR proved they are prepared to roll up their sleeves and battle as they established daylight between themselves and the bottom three.
Although manager Mark Hughes knows there is still an awful lot more hard work ahead if his strugglers are to avoid relegation, with three of the remaining five games against Tottenham (home), Chelsea (away) and Manchester City (away), he will have been pleased with his side's application to the job.
Did you know?
QPR have had seven Premier League red cards this season, including four in their last 10 top flight matches
Swansea have won an army of new admirers after bringing a breath of fresh air to the Premier League.
Yet for all their attractive play, the Welsh club have stumbled in recent weeks and arrived at Loftus Road desperate for a win to make absolutely sure of securing their top flight future.
With so much at stake it was perhaps understandable that chances were limited in a tense first half.
Barton came to his team's rescue after Taye Taiwo's attempted clearance from a Swansea corner threatened to result in an own goal while Routledge spurned a glorious chance for the visitors when he blazed over with a first-time shot.
But QPR were hungrier and more determined than their opponents.
Rodgers apologetic after defeat
Buzsaky flashed a volley narrowly wide while Mackie should have done better than shoot tamely at Michel Vorm before Barton broke the deadlock at the end of the half.
The former Manchester City player is not known for his goalscoring exploits but the 29-year-old produced an unstoppable finish from the edge of the area after Taarabt's free kick into the Swansea area was headed out into his path.
Swansea looked jaded and fell 2-0 behind when Mackie fired home from 25 yards with the aid of a deflection off Rangel following Anton Ferdinand's well-weighted pass.
QPR added a third through Buzsaky, the Hungarian finding the net from 25 yards with a rasping drive which gave Vorm no chance.
Gylfi Sigurdsson takes a shot. Blocked by Clint Hill. Short corner worked by Gylfi Sigurdsson.
Free kick awarded for an unfair challenge on Bobby Zamora by Alan Tate. Akos Buzsaky takes the free kick.
Gylfi Sigurdsson delivers the ball, Danny Graham has a header from close in and clears the crossbar.
Booking Taye Taiwo goes into the book for unsporting behaviour.
Free kick awarded for an unfair challenge on Danny Graham by Taye Taiwo.
Free kick awarded for an unfair challenge on Nathan Dyer by Adel Taarabt. Direct free kick taken by Angel Rangel.
Adel Taarabt takes the outswinging corner, Shot from 20 yards from Joey Barton. Save by Michel Vorm.
Joe Allen concedes a free kick for a foul on Jamie Mackie. Adel Taarabt crosses the ball in from the free kick, Alan Tate manages to make a clearance.
The assist for the goal came from Adel Taarabt.
66:10 Goal scored
Goal - Akos Buzsaky - QPR 3 - 0 Swansea Akos Buzsaky fires in a goal from long distance to the bottom left corner of the goal. QPR 3-0 Swansea.
Corner taken by Gylfi Sigurdsson, clearance by Akos Buzsaky.
Joey Barton has an effort at goal from outside the area missing to the wide right of the goal.
Joe Allen gives away a free kick for an unfair challenge on Joey Barton. Anton Ferdinand restarts play with the free kick.
Substitution (Swansea) makes a substitution, with Luke Moore coming on for Leon Britton.
Free kick awarded for a foul by Samba Diakite on Scott Sinclair. The free kick is delivered right-footed by Gylfi Sigurdsson from left wing. Gylfi Sigurdsson takes the inswinging corner, clearance by Bobby Zamora.
Joey Barton gives away a free kick for an unfair challenge on Ashley Williams. Free kick taken by Gylfi Sigurdsson.
Assist by Anton Ferdinand.
54:10 Goal scored
Goal - Jamie Mackie - QPR 2 - 0 Swansea Goal scored by Jamie Mackie from the edge of the penalty area to the bottom left corner of the goal. QPR 2-0 Swansea.
Jamie Mackie takes a shot. Ashley Williams gets a block in. Samba Diakite has an effort at goal from just outside the box which goes wide of the right-hand post.
Alan Tate gives away a free kick for an unfair challenge on Jamie Mackie. Jamie Mackie restarts play with the free kick.
Joe Allen takes a shot. Save made by Patrick Kenny.
The referee blows for offside. Patrick Kenny restarts play with the free kick.
The second half begins.
Substitution Alan Tate comes on in place of Neil Taylor.
Substitution Nathan Dyer comes on in place of Wayne Routledge.
45:00 +1:45 Half time
Half Time It is the end of the first-half.
Assist by Adel Taarabt.
45:00 +0:22 Goal scored
Goal - Joey Barton - QPR 1 - 0 Swansea Joey Barton finds the net with a goal from inside the box to the bottom left corner of the goal. QPR 1-0 Swansea.
Foul by Neil Taylor on Bobby Zamora, free kick awarded. Adel Taarabt delivers the ball from the free kick right-footed from right wing, clearance by Steven Caulker.
Outswinging corner taken by Gylfi Sigurdsson from the right by-line played to the near post, Bobby Zamora manages to make a clearance.
Akos Buzsaky takes a shot. Blocked by Steven Caulker. Adel Taarabt takes a inswinging corner to the near post, save made by Michel Vorm. Bobby Zamora conjures a left-footed shot from inside the six-yard box that clears the bar.
Patrick Kenny fouled by Scott Sinclair, the ref awards a free kick. Direct free kick taken by Patrick Kenny.
Angel Rangel takes a shot. Save by Patrick Kenny.
Foul by Leon Britton on Joey Barton, free kick awarded. Free kick crossed right-footed by Adel Taarabt, clearance made by Danny Graham.
Scott Sinclair takes a shot. Clint Hill gets a block in. Effort on goal by Wayne Routledge from just inside the penalty area goes over the target.
Foul by Joe Allen on Joey Barton, free kick awarded. Nedum Onuoha takes the free kick.
Corner from right by-line taken by Adel Taarabt. Effort on goal by Joey Barton from just outside the penalty area goes harmlessly over the target.
Corner taken right-footed by Gylfi Sigurdsson to the near post, Anton Ferdinand makes a clearance.
Jamie Mackie takes a shot. Save by Michel Vorm.
Adel Taarabt takes a shot. Save by Michel Vorm.
Corner taken by Gylfi Sigurdsson from the right by-line. Inswinging corner taken right-footed by Gylfi Sigurdsson, clearance made by Joey Barton. Corner taken by Gylfi Sigurdsson from the right by-line played to the near post, Close range headed effort by Steven Caulker clears the crossbar. Danny Graham fouled by Anton Ferdinand, the ref awards a free kick. Direct free kick taken by Neil Taylor.
Corner taken right-footed by Adel Taarabt to the near post, Danny Graham makes a clearance.
Corner taken right-footed by Gylfi Sigurdsson, inswinging corner taken right-footed by Gylfi Sigurdsson from the left by-line, clearance by Joey Barton. Outswinging corner taken by Gylfi Sigurdsson from the right by-line played to the near post, Header from close range by Steven Caulker clears the bar. Free kick awarded for a foul by Anton Ferdinand on Danny Graham. Neil Taylor takes the direct free kick.
Adel Taarabt takes a shot. Blocked by Steven Caulker. The offside flag is raised against Jamie Mackie. Michel Vorm restarts play with the free kick.
Danny Graham takes a shot. Blocked by Clint Hill.
Effort from outside the box by Akos Buzsaky goes wide right of the target.
The ref blows the whistle to start the match.
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.