Phil Jevons gave the Shrimps the lead after 33 minutes when he latched on to Laurence Wilson's square ball to beat Kenny Arthur low to his left. Five minutes later the home side doubled their advantage when Ian Craney robbed Tom Kennedy of possession and fired a low shot past Arthur from the edge of the area.
To make matters worse for the Hornets their defence was caught out again by Jevons as he nipped in between defender and goalkeeper to poke the ball into the empty net.
But then Keith Hill's side picked themselves up and dominated the second 45 minutes.
Chris Dagnall started the fightback with a goal after 48 minutes thanks to a low finish and a header from Joe Thompson was followed by a fine 20-yard strike by substitute Dale Stephens to set up a thrilling finale with both sides missing chances to win the game.
Rochdale move up to ninth in the table, while Morecambe are down in 20th.