A federal judge has ruled that Idaho's ban on same-sex marriage is unconstitutional.

The ruling, handed down by U.S. Magistrate Judge Candy Dale on Tuesday, followed oral arguments on May 5.

Earlier Tuesday, Idaho Gov. Butch Otter (R) filed a preemptive motion asking for an immediate stay if Dale did rule against the gay marriage ban.

“In the event of an adverse order, Gov. Otter will timely and duly appeal it to the Ninth Circuit Court of Appeals,” the governor’s motion reads, according to the Spokesman-Review.

Below, more from the Associated Press:

A federal magistrate judge ruled Tuesday that Idaho's ban on same-sex marriage is unconstitutional.

U.S. District Magistrate Judge Candy Dale wrote in the decision that Idaho's laws banning same-sex marriage unconstitutionally deny gay and lesbian citizens their fundamental right to marry.

Dale said marriage works a fundamental change on the lives of all who experience it, and it holds immense personal and spiritual significance.

Idaho's laws wrongly stigmatize gay and lesbian couples and relegate their families to second-class status without sufficient reason, she said.

Gov. C.L. "Butch" Otter already has said he intends to appeal the case.

"In 2006, the people of Idaho exercised their fundamental right, reaffirming that marriage is the union of a man and a woman," Otter said in a statement. "Today's decision, while disappointing, is a small setback in a long-term battle that will end at the U.S. Supreme Court. I am firmly committed to upholding the will of the people and defending our Constitution."

Idaho Attorney General Lawrence Wasden said he would consult with the governor on the state's appeal.

Four Idaho couples filed the lawsuit challenging the marriage ban in November, against the governor and Ada County Clerk Chris Rich. The couples are Sue Latta and Traci Ehlers; Lori and Sharene Watsen; Shelia Robertson and Andrea Altmayer; and Amber Beierle and Rachael Robertson.

Latta and Ehlers married in 2008 in California, and the Watsens married in 2011 in New York. Both couples have children and say Idaho wrongly treats Ehlers as a legal stranger to her grandchildren and requires Lori Watsen to obtain a new power of attorney every six months so she can have legal authority to consent to medical treatment for her son.

Their attorney, Deborah Ferguson, said the ruling recognized that the families are part of Idaho's community and that they deserved the same protections and respect as other Idaho families.