Well before Senators Barack Obama and John McCain rose to the top of their parties, a partisan shift was under way at the local and state level. For more than three years starting in 2005, there has been a reduction in the number of voters who register with the Republican Party and a rise among voters who affiliate with Democrats and, almost as often, with no party at all.

While the implications of the changing landscape for Mr. Obama and Mr. McCain are far from clear, voting experts say the registration numbers may signal the beginning of a move away from Republicans that could affect local, state and national politics over several election cycles. Already, there has been a sharp reversal for Republicans in many statehouses and governors’ mansions.

In several states, including the traditional battlegrounds of Nevada and Iowa, Democrats have surprised their own party officials with significant gains in registration. In both of those states, there are now more registered Democrats than Republicans, a flip from 2004. No states have switched to the Republicans over the same period, according to data from 26 of the 29 states in which voters register by party. (Three of the states did not have complete data.)

In six states, including Iowa, New Hampshire and Pennsylvania, the Democratic piece of the registration pie grew more than three percentage points, while the Republican share declined. In only three states  Kentucky, Louisiana and Oklahoma  did Republican registration rise while Democratic registration fell, but the Republican increase was less than a percentage point in Kentucky and Oklahoma. Louisiana was the only state to register a gain of more than one percentage point for Republicans as Democratic numbers declined.