(CN) - The Iowa Supreme Court unanimously upheld a ruling that the state's ban on same-sex marriage is unconstitutional, making Iowa one of three states to allow gay marriage.
The justices agreed with Polk County Judge Robert Hanson that a state law defining marriage as a heterosexual union violated the civil rights of same-sex couples, including the six couples who filed suit in Polk County District Court.
Justice Cady noted that the state motto is: "Our liberties we prize and our rights we will maintain."
"We have a constitutional duty to ensure equal protection of the law," Cady wrote. "Faithfulness to that duty requires us to hold Iowa's marriage statute ... violates the Iowa Constitution. To decide otherwise would be an abdication of our constitutional duty. If gay and lesbian people must submit to different treatment without an exceedingly persuasive justification, they are deprived of the benefits of the principle of equal protection upon which the rule of law is founded."
The justices rejected Polk County's stated reasons for the ban, such as preserving the "integrity of traditional marriage," providing an optimal environment for raising children, encouraging procreation and conserving resources.
"While the objectives asserted may be important (and many are undoubtedly important), none are furthered in a substantial way by exclusion of same-sex couples from civil marriage," Cady wrote.
The court also addressed religious opposition to gay marriage, recognizing that many people could not accept the concept based on a "sincere, deeply ingrained - even fundamental - religious belief."
But the court said judges must distance themselves from religious debates and focus on how the concept of civil marriage and the state licensing system affects civil liberties.
"[C]ivil marriage must be judged under our constitutional standards of equal protection and not under religious doctrines or the religious views of individuals," the court wrote.
The justices said the ruling should be interpreted and applied in a way that allows gay couples full access to civil marriage.
The ruling makes Iowa the first Midwest state to allow gay marriage. Iowa joins Connecticut and Massachusetts as the only states where gay couples can marry legally.
In 2008, the California Supreme Court similarly upheld gay couples' right to marry, but voters later repealed the right with Proposition 8, a controversial amendment to the state Constitution that restricts marriage to opposite-sex couples.
Read the Top 8
Sign up for the Top 8, a roundup of the day's top stories delivered directly to your inbox Monday through Friday.