The agreement ensures that election officials count votes cast provisionally when voters use the last four digits of their Social Security numbers, U.S. District Judge Algenon Marbley said Monday. He extended the order until the end of 2016, after the next presidential election in the battleground state.

Marbley said that without the decree, "there is nothing to prevent boards of election from returning to those haphazard and, in some cases, illegal practices, which previously resulted in the invalidation of validly cast ballots from registered voters."

The case stems from a 2006 state law that specified when provisional ballots could be counted toward vote totals. Under the law, a person who provided the last four digits of his or her Social Security number could vote provisionally. Advocates for homeless voters challenged the law in a federal complaint that year. And in 2010, then-Secretary of State Jennifer Brunner, the state's top elections official, entered into the consent decree.

The decree included more options for provisional ballots and voter ID. For example, it incorporated a directive from Brunner that allows letters from public universities to serve as government documents for voting purposes. In addition, it defined "current" as a document issued within a year immediately preceding the date of the election in which a person seeks to vote.

The decree was set to expire June 30, but it was temporary extended while the court weighed arguments.

Voter advocates had the decree extended indefinitely or at least until 2021. Marbley said the law didn't support an indefinite extension.

A lawyer representing homeless voters told the federal court in Columbus last month that without the decree, the state would return to the "Wild West," in which county election boards could apply vague requirements and some voters would be disenfranchised.

Secretary of State Jon Husted said there was no evidence that a single Ohioan would be denied the right to vote if the order expired. Husted's attorneys argued that the decree wasn't necessary, and Husted was committed to following the rules it sets out.

Marbley noted that secretaries of state change frequently, and there's no guarantee a Husted successor would make the same commitment.

"A citizen's right to vote, however, cannot be at the mercy of the shifting legal interpretations of a single state officer, no matter how well intentioned he or she is," he wrote.

A Husted spokesman said the ruling doesn't change how elections in Ohio are currently administered, and the office hasn't determined whether to appeal it.

"Until the General Assembly takes action to change the law, as it relates to these provisions, the courts are going to continue to rule on these matters," said Matt McClellan, a Husted spokesman.

Arguing for the extension, Cleveland attorney Subodh Chandra said in court filings that without the order, homeless and poor voters who lack identification would in effect have to pay a "poll tax" to cast a ballot because they'd have to pay for proper identification.

But attorneys for the state said the advocates' "strained" reading of the law was incorrect.

Chandra, who argued on behalf of the Northeast Ohio Coalition for the Homeless and the Columbus Coalition for the Homeless, praised the ruling. He said there was no reason for Husted to appeal.

"If the consent decree doesn't really do anything, as he claims, then why fight it?" Chandra said in an interview. "This is a good day for the right to vote in America's swing state."

The Ohio Democratic Party also joined the plaintiffs in the lawsuit.

Marbley, who is black, grew up in the South and received his bachelor's degree from the University of North Carolina. He has often spoken of the importance of voting rights to him personally based on events he saw growing up.