Millwall took an early lead through Lee Gregory but David Brooks' volley restored parity before Mahlon Romeo and Jake Cooper struck in the second half.
Sheffield remain in third, while Millwall move up to 18th, seven points clear of the relegation zone.
Millwall started the brighter but the visitors had the first sight of goal after eight minutes, when John Lundstram's strike deflected wide off his own player.
Brooks then went down in the box after leading a Blades breakaway but was cautioned for diving.
Millwall's bright start was rewarded after 14 minutes when a Gregory flick-on released Jed Wallace down the right, who cut inside and fed Steve Morison.
Gregory expertly controlled Morison's return pass and fired across goal and into the net.
Good work from Basham saw Jordan Archer save from Brooks' weak shot as United looked for an instant reply.
Basham then flashed a teasing shot across goal but no one could convert.
A spell of Blades pressure then came to nothing as John Fleck's goal-bound strike was blocked, before the Lions eventually cleared their lines.
Millwall almost doubled their lead from James Meredith's long throw but a flying Jamal Blackman denied George Saville.
On 40 minutes, Mark Duffy clipped a beautiful cross-field ball for Brooks to volley home the equaliser at the far post.
Intricate work in the Millwall box made room for Fleck but his shot cleared the crossbar as both teams upped the pace at the start of the second half.
Neither side could gain a foothold as the game became scrappy in bitter conditions, with Duffy and Morison both wasting half-chances.
With 25 minutes to go, Gregory dispossessed a Blades defender and fed the advancing Romeo, who beat Blackman to fire the hosts ahead.
Wallace then danced through the Blades defence but his toe-poke was deflected behind.
Cooper should have added a third but failed to connect with Shane Ferguson's inviting free-kick from the right.
Millwall continued to control the game and pushed for another goal to kill off the contest, but Wallace's improvised flick failed to trouble Blackman.
But a deserved third came with three minutes left, sealing an impressive and commanding victory for the Lions.
Cooper rose highest to meet Wallace's inswinging free-kick and his header hit the bar before just creeping over the line.
United boss Chris Wilder was withering in his assessment.
He said: “The blame 100 per cent totally lies with me and the team. We haven’t done enough to win but they have.
“This game wasn’t won tactically, in my opinion. It was won because they got to more first and second balls from the off.
“When we got to grips with that, we didn’t punish them when we were on top.
“We made a mistake - nothing tactical. For 20 minutes, we didn’t find the second goal, which we should have done. We make a mistake, they score, and we’re chasing the game.”