Rotherham United 1 Colchester United 2
A Deon Burton penalty gave the home side a first-half lead, but Shaun Barker scored past his own keeper in the second half and Chris Iwelumo claimed the points with a winner five minutes from the end.
Rotherham thought they had taken the lead after just four minutes when Martin Butler drilled a shot past Aidan Davison, but the goal was disallowed for handball.
Colchester, who scored nine in the FA Cup last week, burst forward and almost caught out the home side, but Kemal Izzet smashed a shot over after Phil Gilchrist headed clear.
Rotherham's lead came after 23 minutes when Sam Stockley felled Butler in the area, and referee Graham Salisbury handed the home side a penalty that Burton converted with a cool finish from the spot.
Recalled Rotherham keeper Neil Cutler, out since September, produced a super save to deny Colchester an equaliser after 28 minutes.
Ex-Rotherham midfielder Kevin Watson curled in a dangerous corner that was flicked on and Iwelumo saw his point-blank shot blocked by Cutler. The ball broke to Neil Danns but Paul Hurst was well placed at the post to clear.
Rotherham winger Andy Monkhouse could have stretched the home side's lead but his tame header was easily claimed by Davison.
And when Monkhouse broke from his own half he cut inside and then smashed another shot wide, before Danns headed wide at the other end.
Ten minutes into the second half Colchester were level thanks to an own goal from centre-back Barker. Watson curled in a cross and as Barker slid in to try and clear, he forced the ball past Cutler.
Then, five minutes from the end Danns burst down the left and crossed for Iwelumo to ram home his seventh of the season.