By the time he took the case that would cost him his freedom, Chen Guangcheng had established his fearlessness. The blind and self-educated legal advocate had fought polluters and tax authorities in Shandong province and had pushed for the rights of people with disabilities since the late 1990s.

In 2005, the authorities decided to rein in Chen after he took on the cause of peasants who were being forcibly sterilized or taken to abortion clinics. Incensed by the practice, Chen decided to confront the bureaucrats who were still pursing a coercive one-child policy long after the state had declared such measures illegal.

“He is a genuinely idealistic person shaped by his rural experience, and especially that of being a blind man,” said Jerome A. Cohen, a professor at New York University and a friend of Chen’s. “He is a very driven person. Can you imagine the steely determination to live through what this guy has lived through, and what he has accomplished?”

Chen’s decision to challenge the authorities in court ultimately led to a four-year prison sentence on what human rights groups called trumped-up charges. When he was released in September 2010, Chen was immediately subjected to a new form of incarceration — an unofficial, even unacknowledged, house arrest.

His modest farmhouse in a village outside Linyi city, about 400 miles southeast of Beijing, was surrounded by high walls and cellphone jammers. His detention was enforced by a band of police officers and locally hired thugs.

Chen broke through this cordon last month and into the center of U.S.-China relations when he sought and received refuge at the U.S. Embassy in Beijing.

It was a typically daring moment for the mop-haired, 40-year-old gadfly, who has been defying the odds for much of his life.

Chen, who is married with two children, lost his sight in infancy because of a fever and inadequate medical care. He received no formal education until he was a teenager, starting and finishing elementary school between the ages of 17 and 20.

He attended a university in Nanjing where he studied traditional medicine. But it was the law that attracted him most, and he believed he could use it to redress discrimination faced by people with disabilities. With help from his four older brothers, who read textbooks to him, Chen immersed himself in the subject.

After returning from university studies in Nanjing, Chen quickly became known in his hometown as someone who was willing to go to court to defend the rights of ordinary citizens.

For a time, his activism was tolerated. Chen was not a traditional democracy advocate. He did not attack the Communist Party or the system but repeatedly exposed failures to abide by the law as it was written.

When Chen stood up against the ostensibly illegal but widespread use of forced sterilization and forced abortions, however, he became a target for the provincial government in Linyi, a city of 10 million people.

Local people described women who were eight months pregnant being forced to have abortions. One or both parents of two children were forcibly sterilized, and relatives were held hostage until they complied, Chen reported. All this happened even though the government had outlawed coercion to achieve its development and population goals.

“To Chen, it was another maddening example of the party ignoring its own laws, and when his neighbors asked him what they should do, he suggested a class-action lawsuit against local officials,” wrote Philip P. Pan, a former Washington Post reporter, in his book “Out of Mao’s Shadow: The Struggle for the Soul of a New China.” “In the quarter century since the party adopted the one-child policy, no one had ever attempted a mass legal challenge against the state’s power to compel sterilization and abortion.”

When Chen went to Beijing to discuss the case, he was followed by security agents from Linyi who, after several attempts, detained him and bundled him into a car. Pan, who was called to the scene after Chen was held, said that he saw him pinned face down in the car and he could hear “muffled screaming.”

Chen was eventually sentenced to four years in prison for organizing a mob to block traffic and damaging property. When he was released, he was immediately imprisoned in his home.

The Chinese authorities, when asked, insisted he was a free man.

“I was in a small prison, and now I am in a larger prison,” said Chen in a video that was smuggled out, an act that brought such a severe beating that the dissident was left unconscious, human rights groups said.

As the house arrest continued, dozens of people attempted to visit Chen, most famously the actor Christian Bale, who in December scuffled with Chen’s guards in an episode that was captured by a CNN film crew.

For several months before his escape on April 22, Chen feigned illness to lull his guards into complacency. On the night he fled his home, Chen scaled the wall that had been built to keep him in, badly injuring his foot as he fell to the ground. He struggled on to a rendezvous point.

Friends drove him to Beijing and sheltered him while they contacted the U.S. Embassy. He was picked up by U.S. officials, who eluded a Chinese tail and whisked him into the American compound. He stayed there for six days before leaving Wednesday, after many hours of tense talks between U.S. and Chinese authorities about his future.

In an interview Thursday from his hospital bed, where Chen was admitted for treatment of a cracked bone, he said he wanted to continue “to promote social progress and judicial system improvement in China.”

“Society must become more and more fair in the future,” Chen said. “It’s just a matter of time. It depends on how many people make efforts and how big the efforts we make are.”

Cohen said Chen’s fluctuating statements in recent days — expressing a desire to remain in China, then asking for asylum, and then requesting only a temporary stay in the United States — reflect his conflicting priorities and the avalanche of advice he has received.

Cohen said he believes Chen is torn between the legal work he wants to continue and the safety of his family, which fellow activists say has been threatened with retaliation by Chinese authorities.

“He is uncertain about what he wants,” Cohen said. “How could he not be conflicted? On the one hand, he has his work. On the other, he has a wonderful wife and two lovely children.”

Staff writer Keith Richburg in Beijing contributed to this report.