The Supreme Court on Monday upheld Arizona's independently drawn congressional districts, ruling that the Constitution does not give partisan legislatures exclusive control over redistricting.

The 5-4 decision rejected a constitutional challenge from Republican lawmakers in the state, and preserves efforts in 13 states to prevent partisan influence over the drawing of electoral boundaries, reported The Associated Press.

"The people of Arizona turned to the initiative to curb the practice of gerrymandering and, thereby, to ensure that Members of Congress would have 'an habitual recollection of their dependence on the people,'" wrote Justice Ruth Bader Ginsburg in the majority opinion, quoting the Federalist Papers. "The Elections Clause does not hinder that endeavor."

Ginsberg continued, citing a 2005 gerrymandering case: "In so acting, Arizona voters sought to restore 'the core principle of republican government,' namely, 'that the voters should choose their representatives, not the other way around.'"

Arizona formed its Independent Redistricting Commission 15 years ago after voters amended the state Constitution to take redistricting power away from the Legislature, reported NPR.

Such independent commissions "may be the only meaningful check" left to states that want to encourage more competitive elections, the Obama administration said, according to AP.

A list of 25 people is compiled by a group that also picks judicial candidates, and top Republican and Democratic leaders in the two legislative chambers each choose a member from the list. Once the commission draws up redistricting plans, legislative leaders are allowed to comment, but cannot alter the maps, and the governor cannot veto them, explains The Washington Post.

The only other state to diminish the legislature's role to such an extent is California. In other states - Connecticut, Hawaii, Idaho, Indiana, Iowa, Maine, Montana, New Jersey, New York, Ohio and Washington state - lawmakers are more involved in the process, the National Conference of State Legislatures told AP.

After the once-a-decade census, states are required to re-draw the congressional and state legislative district maps to account for population changes. When partisan lawmakers intentionally draw - sometimes strangely shaped - districts to favor their political party over another by giving them a numeric advantage, it's referred to as gerrymandering.

In 2012, after the Arizona commission's U.S. House map produced four safe districts for Republicans, two for Democrats and made the remaining three seats competitive, the legislature's Republican leaders filed their lawsuit, according to AP.

Joining Ginsberg in the majority were Justices Anthony Kennedy, Stephen Breyer, Sonia Sotomayor and Elena Kagan.

In his dissent, Chief Justice John Roberts accused the majority of approving a "deliberate constitutional evasion" and using a "magic trick" to impose its policy preferences.

"No matter how concerned we may be about partisanship in redistricting, this court has no power to gerrymander the Constitution," Roberts wrote. Justices Antonin Scalia, Clarence Thomas and Samuel Alito joined him in dissent.