Ari Faber has lived as a man for nine years. But because of a state law, Mr. Faber, a Democratic candidate for the Ohio Senate, will appear on ballots in a March primary election with a woman’s name.

The law, which was passed in 1995 to prevent deception, requires candidates who have changed names in the last five years to list previous names on election petitions. It has become an obstacle for Mr. Faber, who has not legally changed his name, and the three other transgender people seeking a seat in Ohio’s Legislature this year.

One candidate was disqualified for failing to do so; another saw her campaign challenged; a third campaign faced a disqualification hearing; and Mr. Faber was directed to run under his deadname, a term that transgender people use for a birth name that they no longer use.

The law’s uneven application across four counties comes as Ohio joins other states with Republican-controlled Legislatures in limiting transgender people’s access to what is known as gender-affirming care, while barring them from sports teams and public bathrooms that correspond with their gender identities.

The confusion over the names law in Ohio also reflects how transgender people across the country are struggling to adapt to systems that had not accounted for their existence.

It has also created uncertainty. The candidates whose campaigns have been allowed to continue fear that another interpretation of the law could result in a disqualification later in the race, or a removal from office if elected.