Rotherham United 0 Sheffield Wednesday 1 - Atdhe Nuhiu grabs late winner to send the Owls into the third round of the Carabao Cup
For the first time since 2015, Sheffield Wednesday's League Cup run will stretch into September.
Atdhe Nuhiu broke Rotherham United's hearts deep into added on time, scrambling the ball home in from inside the six-yard box after the hosts failed to deal with Kadeem Harris's cross.
It is the third time in their last five visits to the ASSEAL New York Stadium that the Owls have scored at the death.
"Rotherham United, it has happened again" taunted Wednesday's sold-out away end following Nuhiu's late winner.
Backed by over 2,600 noisy Owls supporters, Lee Bullen's much-changed side struggled for long periods.
Caretaker boss Bullen gave the night off to several of his leading lights, including Keiren Westwood, Sam Hutchinson, Kieran Lee and Steven Fletcher.
Only Morgan Fox and Jacob Murphy from the starting XI in Saturday's away defeat to Preston North End were in the line up to face the Millers. There was a mixed reaction to the team, with the exclusion of Fernando Forestieri irking some Wednesdayites on social media.
Of those who came in, few players pressed their claims to be involved in the Championship duel with Queens Park Rangers this weekend.
Jordan Thorniley acquitted himself well in defence alongside debutant David Bates while Massimo Luongo, handed his first start in midfield since arriving from QPR, was energetic in the middle of the park.
Joey Pelupessy, wearing the captain's armband, drilled a shot over following good approach play by Jacob Murphy and Sam Winnall inside the opening 30 seconds as Wednesday started on the front foot.
But the visitors quickly lost their way and Cameron Dawson produced a smart stop to keep out Rotherham midfielder Ben Wiles' downward header.
There was a lack of cohesion to Wednesday's work, with Rotherham dominating posessiong and carrying the greater attacking threat.
Freddie Ladapo, the Millers club-record signing, wasted a glorious opportunity to give the hosts a 10th minute lead after a clever set-piece from Dan Barlaser but the striker fired a low shot wide.
Bullen was clearly unimpressed with their sluggish start to proceedings and switched Sam Winnall, a centre-forward by trade, from the left wing to right flank in their 4-4-2 formation.
Despite playing out of position, Winnall showed flashes of his quality on the ball. He skipped down the right before whipping in an inviting cross that had to be chested behind by Matt Olosunde.
It took Wednesday, who received a bye into the secound round after Bury were expelled from the competition, until the 24th minute to register their first attempt on target, with Nuhiu heading Dominic Iorfa's delightful cross straight at Daniel Iversen.
Jordan Rhodes looked off the pace for long periods of a turgid first half but he almost gave the Owls the lead. The former Middlesbrough player saw his firm header from a wonderful delivery by Fox tested the reflexes of Iversen.
Moments later, Rotherham should have got their noses in front after Ladapo raced on to Michael Smith's neat knock down but the forward poked his shot inches wide.
The Millers, hunting in packs and closing the Owls down fast in possession, finished a dull opening 45 minutes on top and Dawson superbly turned away Smith's fierce 20 yard strike.
Bullen was forced into a personnel change before the second half kicked off. Winnall suffered a head injury at the end of the first period and complained of dizziness to the away bench and was replaced by Kadeem Harris.
Their disjointed, unconvincing performance continued after the break as Matt Crooks fizzed in a super cross from the right that just evaded Smith in the centre.
Fox then produced a magnificent last-ditch challenge to prevent Wiles from latching on to a loose ball in the penalty area.
Against the run of play, the Owls came close to opening the scoring when Murphy threaded a pass through to Nuhiu. The Kosovo international's low drive was expertly blocked by Iversen, who spread himself well to narrow the angle.
Barry Bannan livened Wednesday up in midfield following his introduction from the bench. His first touch caused havoc in the Millers penalty area as Nuhiu steered his free kick against the post but the offside flag had been raised.
Fox steered a header wide at the back post as the tie looked like going to penalties only for Nuhiu to have the final word as he bagged his first goal of the campaign.
Rotherham: Iverson; Olosunde, Wood, Ihiekwe, Robertson; Wiles, Barlaser (MacDonald 67), Crooks (Lindsay 61); Vassell, Ladapo, Smith (Proctor 74). Substitutes: Bilboe, Mattock, Thompson, Cooper.
Owls: Dawson; Iorfa, Bates, Thorniley, Fox; Murphy (Bannan 65), Luongo, Pelupessy (Forestieri 76), Winnall (Harris HT); Nuhiu, Rhodes. Substitutes: Jones, Lees, Baker, Grant.
Attendance: 8,679 (2,601).
Referee: Charles Breakspear (Surrey)
Star man: Massimo Luongo