"I think that the more freely information flows, the stronger the society becomes, because then citizens of countries around the world can hold their own governments accountable," Mr. Obama said Monday in a town hall with students during his first-ever trip to China. "They can begin to think for themselves." (Read the transcript of the entire town hall.)
Just hours ahead of talks with Chinese President Hu Jintao, Mr. Obama tried to find a political balance, couching his admonitions with words of cooperation, praise and American humility.
As Mr. Obama arrived for the state visit, police detained dozens of activists and petitioners in Beijing and elsewhere in China, friends,
family members and a human rights group said Monday.
At the Shanghai forum, Mr. Obama said few global challenges can be solved unless the world's only superpower and its rising competitor work together, and he insisted: "We do not seek to contain China's rise."
But in his opening statement and in answers to the wide-ranging discussion with university students, Mr. Obama spoke bluntly about the benefits of individual freedoms in a place known for limiting them.
The meeting with students was broadcast locally, but not nationwide. Most of the eight questions, from students and the Internet, were polite expressions of chinese government policy," reports CBS News senior White House correpsondent Bill Plante.
Read more about Obama's comments on Internet freedoms
Access to Obama Remarks Blocked in China
"We do not seek to impose any system of government on any other nation," Mr. Obama said. Then he added that freedom of expression and worship, unfettered access to information and unrestricted political participation are not principles held by the United States; instead, he called them "universal rights."
The line offered echoes of Mr. Obama's predecessor, George W. Bush, who often talked of the "universality of freedom." Mr. Obama talked at length about the Internet, which he said helped him win the presidency because it allowed for the mobilization of young people like those in his audience in Shanghai.
"I'm a big supporter of non-censorship," Mr. Obama said. "I recognize that different countries have different traditions. I can tell you that in the United States, the fact that we have free Internet - or unrestricted Internet access is a source of strength, and I think should be encouraged."
Given where Mr. Obama was speaking, such a comment carried strong implications. And he appeared to be talking directly to China's leaders when he said that he believes free discussion, including criticism that he sometimes finds annoying, makes him "a better leader because it forces me to hear opinions that I don't want to hear."
China has more than 250 million Internet users and employs some of the world's tightest controls over what they see. The country is often criticized for having the so-called "Great Firewall of China," which refers to technology designed to prevent unwanted traffic from entering or leaving a network.
Mr. Obama's town hall was not broadcast live across China on television. It was shown on local Shanghai TV and streamed online on two big national Internet portals, but the quality was choppy and hard to hear.
Photo Essay: Obama in China
President Obama, Can We Twitter?
Transcript: Obama's Town Hall in China
In China, Obama Meets America's Lender
U.S., China Fuel Each Other's Bad Habits
Mr. Obama is in the midst of a weeklong Asia trip. He came with a vast agenda of security, economic and environmental concerns, although always looming was how Mr. Obama would deal with human rights while in China.
The president left Shanghai for Beijing, where was to spend Monday night after meeting with his Chinese counterpart.
Mr. Obama's China visit features the only sightseeing of his journey. He will visit the Forbidden City, home of former emperors in Beijing, and the centuries-old Great Wall outside of the city. Aides have learned that finding some tourist time calms and energize their boss amid the grueling schedule of an international trip.
U.S. ambassador Jon Huntsman called Mr. Obama's event the first ever town-hall meeting held by a U.S. president in China. Yet former presidents Bill Clinton and George W. Bush also spoke to students and took questions from them during stops in China.
China is a huge and lucrative market for American goods and services, and yet it has a giant trade surplus with the U.S. that, like a raft of other economic issues, is a bone of contention between the two governments. The two militaries have increased their contacts, but clashes still happen and the United States remains worried about a dramatic buildup in what is already the largest standing army in the world.
Amid all that, Mr. Obama has adopted a pragmatic approach that stresses the positive, sometimes earning him criticism for being too soft on Beijing - particularly in the area of human rights abuses and what the United States regards as an undervalued Chinese currency that disadvantages U.S. products.
The two nations are working together more than ever on battling global warming, but they still differ deeply over hard targets for reductions in the greenhouse-gas emissions that cause it. China has supported sterner sanctions to halt North Korea's nuclear weapons program, but it still balks at getting more aggressive about reining in Iran's uranium enrichment.
Mr. Obama recognizes that a rising China, as the world's third-largest economy - on its way to becoming the second - and the largest foreign holder of U.S. debt, has shifted the dynamic more toward one of equals. For instance, Chinese questions about how Washington spending policies will affect the already soaring U.S. deficit and the safety of Chinese investments now must be answered by Washington.
The White House hoped Monday's town hall meeting with Chinese university students would allow Mr. Obama to telegraph U.S. values - through its successes and failures - to the widest Chinese audience possible.
But those hopes had their limits in communist-ruled China.