Classy Palace carved out the chances as they snatched two goals to nudge Ronnie Moore's battling side back towards a relegation dogfight.
Julian Gray and Neil Shipperley prized Rotherham apart with goals in the opening half before Michael Proctor gave the Millmoor side an 85th minute lifeline.
Rotherham almost snatched the lead with just 11 seconds gone, Paul Warne's fierce strike being tipped over the bar in spectacular fashion by Nico Vaesen.
Palace, with just four points from their last four games after an impressive eight-match winning streak at the start of the year, should have snatched the lead early on, Shipperley squandering a half-chance as he headed over from eight yards.
Iain Dowie's side grabbed the opener in the 11th minute. Rotherham were slow to close down Wayne Routledge and although his low drive was blocked, Gray steamed in to lash the ball past Mike Pollitt from 15 yards.
Rotherham were caught napping again a minute later, Danny Butterfield pumping an inch-perfect cross to Andrew Johnson who scooped his header over the top from eight yards.
Proctor almost found a way through with a darting run from midfield but his angled drive from 28 yards flashed past the far post. Andy Monkhouse produced a carbon copy move minutes later, but his right-foot strike curled high and wide of the target.
Palace added a second in the 28th minute. With Rotherham's back four looking for an offside flag, Gray crossed from the left and Shipperley finished with a looping header at the far post, his seventh of the season.
Rotherham pulled one back in the 85th minute, John Mullin looping the ball to Proctor who finished with a low strike from 15 yards. He almost snatched an equaliser with seconds to go, but his long-range strike kept out by the diving Vaesen.