A last minute goal from Kevin Ellison earned Morecambe victory over ten-man Rotherham at the Globe Arena.
Ellison scored the vital goal against his former club with a looping header from Andy Wright's right-wing cross that beat Scott Shearer high to his right.
The goal came after the visitors had been reduced to 10 men when skipper Johnny Mullins was sent off in the 71st minute for fouling Wright as he looked set to run on goal.
It proved a big decision as Rotherham had minutes earlier come from behind when Alex Revell deflected a Lionel Ainsworth shot past Barry Roche just after the hour.
Morecambe had started the second half in style when left back Robbie Threlfall scored his first goal for the club with a superb free kick that curled into the bottom right hand corner of Shearer's goal.
The first half saw Rotherham dominate possession but struggle to make any clear chances against a solid Morecambe defence.
Ben Pringle looked sharp and he went close with an early volley before seeing a close range shot in the 24th minute blocked by his own player Michael O'Connor when it looked set to be heading for the bottom left-hand corner.
Rotherham continued to push and had a man over only for O'Connor to waste his final pass after robbing Gary McDonald of possession on the edge of the Shrimps' box.
Lionel Ainsworth went close with a dipping 20-yard shot for the visitors before Jim Bentley's side had their first attempt on goal when Jack Redshaw turned smartly in the box to force a good tip over from Shearer.