PHILADELPHIA — First there was quiet. Then came the “super PACs.” Now the candidate is on his way.

In a striking last-minute shift, the Romney campaign has decided to invest its most precious resource — the candidate’s time — in a serious play to win Pennsylvania.

Mr. Romney’s appearance here on Sunday could be a crafty political move to seriously undercut President Obama, or it could be a sign of desperation. Either way, his visit represents the biggest jolt yet in a state that was until recently largely ignored in the race for the White House.

Over the last several days, with polls showing Mr. Obama’s edge in the state narrowing, Republicans have sprung into action and forced the Democrats to spend resources here that could have gone toward more competitive battleground states.

Conservative super PACs dusted off old advertisements that had not been shown in weeks and shipped them to local television stations from Scranton to Pittsburgh. They ordered millions of dollars in airtime.