Liam Trotter scored twice and sub Darius Henderson bagged his ninth goal of the season as Millwall secured a vital victory against fellow basement boys Doncaster Rovers.
Stand-in skipper Trotter, who took over the captain's armband from the suspended Paul Robinson, fired the first of his brace from the penalty spot on 25 minutes.
Although Donny's Billy Sharp levelled with a 40th-minute spot-kick, Trotter added his - and Millwall's second - with a fine effort just two minutes later.
Sub Darius Henderson looked to have sealed victory for Millwall with an 84th-minute third only for Sharp to set up a nervy finale by reducing the arrears to a single goal once more.
However, despite not producing one of their most fluid performances of the season, The Lions could not be faulted for digging in and grinding out a crucial three points against Dean Saunders' strugglers.
"First and foremost it was an excellent win for us," said Lions boss Kenny Jackett.
"It builds a good gap between us and them. Saying that, we did make hard work of it but there aren't any easy games in the Championship.
Confidence is building and we are a team in transition."
With skipper Paul Robinson ruled out through suspension, Darren Ward stepped in to fill the central defensive berth alongside Shane Lowry in an otherwise unchanged Lions side from the one that started against Crystal Palace.
Likewise Dean Saunders' Donny made one change from the team that drew 0-0 with Watford on Saturday, with Giles Barnes replacing El-Hadj Diouf.
In a scrappy opening 45 minutes punctuated by a plethora of misplaced passes from both teams, it was Jackett's men who carved out the first couple of openings.
Trotter's early drive was punched over by the strong hand of Donny keeper Carl Ikeme whilst a glancing header by Nathan Baker from Scott Barron's free-kick flew narrowly wide.
Millwall didn't have to wait long to make the breakthrough though. On 24 minutes a raking forward pass down the line by Barron sent John Marquis away and the young striker showed great power and determination to shrug off a trio of challenges before Brian Stock hacked him down.
Despite Jay Simpson's attempts to get the ball, there was only one man going to take the penalty and up stepped skipper for the night Trotter to smash home the resulting spot kick.
Three minutes later Marquis was shown a yellow card following a tangle with Donny's Habib Beye that also saw the visiting player escape with a similar punishment despite appearing to raise his hands.
Defender Shane Lowry denied Donny an equaliser with a superb 31st-minute clearance off the line to keep out Herold Goulon's goal-bound header before Simpson tested visiting keeper Ikeme at the other end with a smart shot on the turn.
The visitors hauled themselves level six minutes before the break when Barron tangled withn Sharp. The Donny striker slammed his penalty into the roof of the net giving Steve Mildenhall no chance.
However Donny's celebrations were cut short and just three minutes later produced a well-worked goal. Jack Smith and Trotter played a neat one-two and although the latter still had plenty to do when he picked up the return pass, Trotter showed great composure and skill to slot a low shot under the body of Ikeme and into the far corner.
Mildenhall came to the rescue with a splendid 52nd-minute save to push Marc-Antoine Fortune's fizzer away at full stretch.
The Lions responded and Lowry was inches away from scoring his first goal in a Millwall shirt, but his low shot from another Barron free-kick smacked the foot of the post.
Jackett's men dominated much of the second period thereafter, with Simpson's fierce drive blocked and then the same player sent a first-time volley over the bar from Barron's dinked delivery.
However Millwall had to wait until six minutes from time for their third as substitute Hamer Bouazza's inch perfect free-kick was headed over the line by fellow replacement Henderson.
The two-goal advantage lasted just two minutes, though, as Sharp nodded Kyle Bennett's centre past Steve Mildenhall to set up a nervy finish.
The Lions did have a great opportunity to restore the two-goal cushion in injury time following a slick, quick counter-attack but Bouazza's final shot from Henderson's inviting pass lacked power and was comfortably cleared.
However, Jackett's men dug in for the four remaining minutes of injury-time to hold on for a first win in four games and three points that move the team up to 17th in the Championship table.
Millwall: Mildenhall, Smith, Baker, Abdou, Ward, Lowry, Barron (Bouazza, 75mins), Trotter, Marquis (Henderson, 61mins), Simpson, Feeney (Henry, 79mins). Subs not used: Allsop, Howard.
Bookings: Marquis (26mins), Lowry (67mins)
Scorers: Trotter (25mins, pen, 43), Henderson (83mins)
Doncaster Rovers: Ikeme, O'Connor, Stock (Coppinger, 80mins), Sharp, Gillett, Barnes, Hird, Ilunga, Antoine-Fortune, Beye (Bennett, 74mins), Goulon (Wilson, 80mins). Subs not used: Sullivan, Hayter.
Bookings: Beye (26mins), Gillett (83mins), O'Connor (90+3mins)
Scorer: Sharp (39mins, pen, 87mins)
Ref: A D'Urso
Att: 9,052 (away 268)