A pivotal vote Thursday in the Minnesota House positioned that state to become the 12th in the country to allow gay marriages and the first in the Midwest to pass such a law out of its Legislature.

The 75-59 vote was a critical step for the measure, which would allow same-sex weddings beginning this summer. It’s a startling shift in the state, where just six months earlier voters turned back an effort to ban them in the Minnesota Constitution.

The state Senate plans to consider the bill Monday and leaders expect it to pass there too. Gov. Mark Dayton has pledged to sign it into law.

“My family knew firsthand that same sex couples pay our taxes, we vote, we serve in the military, we take care of our kids and our elders and we run businesses in Minnesota,” said the bill’s sponsor, Rep. Karen Clark, a Minneapolis Democrat who is gay. “… Same-sex couples should be treated fairly under the law, including the freedom to marry the person we love.”

Hundreds of supporters and opponents gathered outside the House chamber up to and during the debate, chanting and waving signs. They sang “We Shall Overcome” and a John Lennon song in the minutes before the vote.

Four of the House’s 61 Republicans voted for the bill, while two of its 73 Democrats voted against it.

Opponents argued the bill would alter a centuries-old conception of marriage and leave those people opposed for religious reasons tarred as bigots.

“We’re not. We’re not,” said Rep. Kelby Woodard, R-Belle Plaine. “These are people with deeply held beliefs, including myself.”

Pro-marriage demonstrators filled the hallways outside the House chambers, some dressed in orange T-shirts and holding signs that read, “I Support the Freedom to Marry.” Behind them, opponents held up bright pink signs that read simply, “Vote No.”

Among the demonstrators was Grace McBride, 27, a nurse from St. Paul. She said she and her partner felt compelled to be there to watch history unfold. She said she hopes to get married “as soon as I can” if the bill becomes law. The legislation would allow her to do so starting Aug. 1.

“I have thought about my wedding since I was a little girl,” she said.

On the other side of the divide, the Rev. Steve Goold of New Hope Church led followers in a morning prayer before they set out to lobby lawmakers. He told them they had the power to change minds but urged them to be respectful.

“Do not shout and boo. Pray,” Goold said. Galina Komar, a recent Ukrainian immigrant who lives in Bloomington, brought her 4-year-old daughter and 1-year-old son to the Capitol to express her religious concerns.

“I do believe in God, and I believe God already created the perfect way to have a family,” Komar said.

But gay marriage supporters also boasted faith leaders in their ranks.

“I’ve celebrated marriages for same-sex couples, but I’ve never been able to sign a marriage license for any of them,” said the Rev. Jay Carlson, pastor at a Minneapolis Lutheran church. “I look forward to the day when I can.”

Eleven other states allow gay marriages — including Rhode Island and Delaware, which approved laws in the past week. Minnesota would be the first state in the Midwest to pass the measure out of the Legislature.

Iowa allows gay marriages because of a 2009 court ruling. Leaders in Illinois — the only Midwestern state other than Minnesota with a Democratic-led statehouse — say that state is close to having the votes to approve a law too.