Gov. Spencer Cox of Utah vetoed a bill on Tuesday that would have barred young transgender athletes from participating in girls’ sports, becoming the second Republican governor in two days to reject such legislation.
Republican legislators, however, plan to override the veto on Friday, State Senator J. Stuart Adams, a Republican, said in a statement.
Eleven other states have enacted similar laws in recent years as sports participation by transgender girls and women becomes an increasingly divisive topic among political leaders and athletic organizations.
Mr. Cox, a first-term governor up for re-election in 2024, said in a statement that while “politically, it would be much easier and better for me to simply sign the bill,” he chose to veto it because he “tried to do what I feel is the right thing regardless of the consequences.”
Three state legislatures — in Kansas, Louisiana and North Dakota — passed similar bills targeting transgender athletes last year that were ultimately vetoed by their governors.
And on Monday, Gov. Eric Holcomb of Indiana, a Republican, vetoed a similar bill, saying it would likely have been challenged in court and would not have solved any pressing issue.
Mr. Cox’s veto of the bill reflected varied political and personal equations in a state still receptive to a moderate brand of Republicanism exemplified by Senator Mitt Romney, local political figures and analysts said.
Those factors included a fear that anti-transgender legislation is bad for luring and retaining businesses, Mr. Cox’s own history of being sensitive to L.G.B.T.Q. concerns and a frustration with lawmakers in his own party who blindsided him on March 4 when they approved a last-minute version of the bill.
The Republican state senators in Utah had bypassed negotiations with L.G.B.T.Q. rights advocates and state Democrats, who had spent weeks working on a compromise and believed the bill would be held for the next legislative session.
Instead, the Republicans decided hours before the end of the session that only an outright ban on transgender athletes in youth sports would muster the minimum 15 votes needed to pass the bill.
The Utah House of Representatives later approved the amended bill.
State Senator Daniel McCay, who introduced the proposed ban and defended it on the floor of the State Senate, said that he was disappointed by the governor’s decision to veto the bill. Mr. McCay, a Republican, said it was unfair for girls who identify with the gender assigned to them at birth to play against transgender girls.
He said of transgender young people, “Perhaps that choice impacts their availability to play competitive sports at a high school or collegiate level.”
Opponents of his bill disagreed, saying the measure was discriminatory and would adversely affect the mental health of transgender young people.
Mr. Cox quickly denounced the bill after it passed. He had met with lawmakers weeks earlier and expressed his support for creating a commission of experts who would determine eligibility in individual cases. Some lawmakers and transgender-rights advocates pushed back on that idea, too.
Instead, the bill that arrived on Mr. Cox’s desk fully prohibited “the male sex from competing against another school on a team designated for female students.” If a court invalidated the measure, it said, the commission of experts would be established.
After lawmakers approved the legislation, Mr. Cox addressed the transgender community in a news conference, saying: “We care about you. We love you. It’s going to be OK.”
Troy Williams, the executive director for Equality Utah, an L.G.B.T.Q. rights organization, said the governor in recent years has been quick to defend and support the L.G.B.T.Q. community, often at the risk of facing political pushback from his party.
The governor, he said, was “instrumental in helping us ban conversion therapy in the state” in 2020, when Mr. Cox was lieutenant governor.
In 2016, Mr. Cox cried as he delivered a speech a day after 49 people were killed at a gay nightclub in Orlando, Fla., and apologized for not treating gay students in his class in rural Utah “with the kindness, dignity and respect — the love — that they deserved.”
“My heart has changed,” he said to the crowd. “It has changed because of you. It has changed because I have gotten to know many of you. You have been patient with me.”
But others said practical concerns and agendas played a part as well.
Joshua Ryan, an associate professor of political science at Utah State University, said that because the tech industry in the state had grown in recent years, Mr. Cox and other moderate state lawmakers do not want headlines about transgender-related legislation.
“I think the governor and a lot of other Republican legislators, they don’t want to get attention from the national news media on some culture-war issue,” he said.
Matthew Burbank, a political science professor at the University of Utah, said that the governor’s veto could also be a tactical reaction to being “left entirely out of the loop.”
He added that “mixed messages” from the Church of Jesus Christ of Latter-day Saints on being transgender complicate how people will react. Utah boasts the largest population of members of the church in the country.
While the church’s leaders do “not take a position on the causes of people identifying as transgender,” according to the church’s website, they disapprove of transitioning and will limit church practices for those who do so.
Giulia Heyward contributed reporting.