In a defeat for the gay rights movement, Massachusetts' highest court ruled Thursday that same-sex couples from states where gay marriage is prohibited cannot tie the knot in Massachusetts.
Gov. Mitt Romney welcomed the decision, saying he did not want Massachusetts to become "the Las Vegas of same-sex marriage."
The Supreme Judicial Court upheld a 1913 state law that forbids nonresidents to marry in Massachusetts if their marriage would not be recognized in their home state.
If the court had struck down the law, Massachusetts would have been thrown open to gay couples from across the country to get married.
Massachusetts "has a significant interest in not meddling in matters in which another state, the one where a couple actually resides, has a paramount interest," Justice Francis Spina wrote.
The state "can reasonably believe that nonresident same-sex couples primarily are coming to this commonwealth to marry because they want to evade the marriage laws of their home states, and that Massachusetts should not be encouraging such evasion."
The ruling leaves in legal limbo an undetermined number of out-of-state gay couples who married in 2004 in Massachusetts when it became the first state to let gays wed.
According to the Registry of Vital Records and Statistics, 7,341 gay couples married in Massachusetts from May 2004 to December 2005. The state does not track how many out-of-state couples were given licenses.
Six justices ruled against the gay couples in two separate opinions. Only one member of the seven-justice court dissented.