As a result, St. Louis Circuit Judge Rex Burlison said in his decision, marriage licenses could be issued beginning Wednesday.

“The Court finds and declares that any same sex couple that satisfies all the requirements for marriage under Missouri law, other than being of different sexes, is legally entitled to a marriage license,” Burlison wrote.

He said that the Missouri Constitution violates the Equal Protection Clause and Due Process Clause of the 14th Amendment to the U.S. Constitution.

Burlison’s ruling comes more than four months after four couples were married at St. Louis City Hall, even though there is a 10-year-old constitutional amendment defining marriage as between one man and one woman.

The act of defiance, choreographed with the support of Mayor Francis Slay and then-Recorder of Deeds Sharon Carpenter, led Attorney General Chris Koster to file an injunction preventing more marriage licenses from being issued to same-sex couples.

It’s the second major victory in the state for same-sex marriage. Last month, a Kansas City judge ruled that marriages of Missouri gay couples wed in states or countries where such relationships are legally recognized must be honored by their home state. The decision by Circuit Judge J. Dale Youngs was the first by any judge affirming same-sex marriage in Missouri. That ruling affected more than 5,400 Missouri couples.

In both cases, an attorney from Koster’s office defended the state constitution. Koster supports same-sex marriage but said he has a legal responsibility to defend Missouri law. However, after losing the Kansas City case, Koster declined to appeal, saying the state is obligated to honor contracts entered into in other states.

“Missouri’s future will be one of inclusion not exclusion,” Koster said. It was not immediately clear, however, whether Koster would appeal today’s ruling. Gay rights advocates expect Koster will ask the Missouri Supreme Court to make a final ruling.

“This is a positive move forward for loving same-sex couples in the City of St. Louis,” said Jeffrey Mittman, executive director of the American Civil Liberties Union of Missouri. “It is also a win for families throughout Missouri as another discriminatory obstacle is lowered.”

St. Louis City Counselor Winston Calvert said issuing the four marriage licenses in June “pushed the envelope on behalf of families throughout the State of Missouri who now can enjoy the dignity, stability, and security of a legal marriage.”

In arguments before Burlison on Sept. 29, Calvert told the judge that marriage is a fundamental right of all citizens, but the constitutional amendment “categorically denies that right to an entire class of people.”

The landscape of same-sex marriage has changed dramatically since June 2013. That’s when the U.S. Supreme Court struck down a key part of the Defense of Marriage Act. That ruling allowed gay couples who live in states where their marriages are legally recognized to receive the same federal benefits as married opposite-sex couples.

Then last month, the Supreme Court rejected appeals from five states seeking to preserve their bans. There are now 32 states plus the District of Columbia that issue marriage licenses to same-sex couples.

Marc Solomon, national campaign director for Freedom to Marry, said Burlison’s ruling “is very much consistent with the way judges have been ruling around the country since the Supreme Court took up the issue.”

The ruling today marks 49 successful challenges to same-sex marriage laws across the country, compared to three losses, Solomon said.