While India and the United States agreed to cooperate in promoting cleaner energy, Mr. Obama left after three days without the sort of specific commitment to curbing greenhouse gases that he won in China last year. Instead, he used a farewell speech before his departure to argue that India had an obligation to step up, despite its economic challenges.
"I know the argument made by some - that it's unfair for countries like the United States to ask developing nations and emerging economies like India to reduce your dependence on the same fossil fuels that helped power our growth for more than a century," Mr. Obama told an audience of 1,500 mostly young Indians at Siri Fort Auditorium on the final day of his trip here.
"But here's the truth," he added. "Even if countries like the United States curb our emissions, if countries that are growing rapidly like India with soaring energy needs don't also embrace cleaner fuels, then we don't stand a chance against climate change."
The president's remarks came during a speech with a broader tough-love message, lavishing praise on India and pledging friendship while challenging it to cut back on human rights abuses. He urged India to protect the rights of girls and women, combat human trafficking and slavery, promote religious and racial tolerance, and empower young people.
"America can be India's best partner," he said to applause, and he repeated his support for India to become a permanent member of the United Nations Security Council. "But as I've said before, with power comes responsibility."
It was a notably pointed speech at the end of a trip dominated by displays of affection. But Mr. Obama had come under pressure from advocacy groups at home not to leave India without delivering a strong appeal for human rights in a country proud of its democracy.
Just before the speech, in fact, he met with Kailash Satyarthi, the Nobel Peace laureate who has long fought child slavery in India. Mr. Satyarthi told the president that there were still five million child slaves worldwide.
Mr. Obama's speech was aimed partly at his newfound friend, Prime MinisterNarendra Modi, who has been criticized for not doing more to protect political dissent, guard against sectarian discrimination and tackle human trafficking. In effect, Mr. Obama was saying that their developing partnership did not mean Mr. Modi would get a free pass.
But as he often does overseas, Mr. Obama couched his sharp comments with an acknowledgment that the United States had its own flaws, an effort to avoid looking too much like he was lecturing. He cited his own experiences as an African-American. "Even as America has blessed us with extraordinary opportunities, there were moments in my life where I've been treated differently because of the color of my skin," he said.
Mr. Obama appeared particularly impassioned as he talked about the need to stop treating women as second-class citizens. "Every girl's life matters," he said, as his wife, Michelle Obama, watched from the audience. "Every daughter deserves the same chance as our sons. Every woman should be able to go about her day - to walk the street, or ride the bus - and be safe and be treated with respect and dignity. She deserves that."
In a country where human rights groups say tens of millions of people are subject to forced labor, Mr. Obama added that India needed to crack down on that problem. "Together, we can stand up against human trafficking and work to end the scourge of modern-day slavery," he said. But he did not mention the case of an Indian diplomat who was arrested in New York after being accused of exploiting her housekeeper, an episode that roiled the countries' relationship for a time.
Mr. Obama tried to link India's aspirations for its future to America's own efforts to build a better society, noting similarities between the constitutions of the two countries and the diversity of large, multicultural societies.
"As Americans, we believe in the promise of India," he said. "We believe in the people of India. We are proud to be your friend. We are proud to be your partner as you build the country of your dreams."
That message was noticed beyond the auditorium. "Here is a world leader, who is the prime minister's friend, and he is saying, 'This will cost you if you don't stop. You're stepping up to the high table, and sitting at the high table requires you to play by certain rules,' " Praveen Swami, a journalist, said on the television news channel NDTV.
C. Raja Mohan, an analyst speaking on the same channel, said the speech was a warning to Mr. Modi. "It's a good caution to the ruling party: 'Don't think you can keep doing what you're doing domestically and you won't get a reaction from the international community,' " Mr. Mohan said.
Mr. Modi has been careful to stay away from divisive rhetoric since he became prime minister, but he was an activist with a right-wing Hindu organization, Rashtriya Swayamsewak Sangh, before he went into politics. Right-wing groups campaigned very effectively for him, and since he was elected, they have pushed for a more activist agenda.
One group has announced a campaign to convert members of religious minorities to Hinduism, arguing that Muslims or Christians, or their forebears, were originally Hindu themselves. And one of Mr. Modi's ministers recently asked an audience, in a play on words in Hindi, to "decide whether you want a government of those born of Ram, or those born illegitimately," words interpreted as derogatory to Muslims.
Though Mr. Modi is said to have discouraged such rhetoric in private, he has so far made no public comment on these events, as human rights activists have urged him to do.
"Because he is such a strong leader and such a prominent face in government, it always comes down to him, that he isn't speaking," said Meenakshi Ganguly, the South Asia director of Human Rights Watch. "Does that convey the leaning of the administration? Because that is why minorities begin to feel vulnerable."
Beyond India's domestic issues, Mr. Obama's speech seemed aimed at encouraging the country to play a greater role on the world stage. Ms. Ganguly noted that India was a "chronic abstainer" from United Nations resolutions on human rights violations in places like Syria and North Korea.
"It's an important message to say we welcome India to the club of countries that influence global affairs, but in that case you must influence it; you cannot abstain," she said. "You have to accept the responsibility of it."
On a morning when New Delhi was bathed in smog, the president's remarks on climate change touched on one of the central priorities of his meetings with Mr. Modi. Although Mr. Obama and his team had recognized that they would not get the same sort of deal they got in China in November, they were mainly left to announce a series of smaller initiatives.
They took solace from a rhetorical commitment by Mr. Modi to support a United Nations process to develop a global climate agreement in Paris by the end of the year. But the test will be whether India eventually makes specific commitments to reduce the growth of its carbon emissions by a specific date. The president used his speech to push the Indians in that direction.
"With rising seas, melting Himalayan glaciers, more unpredictable monsoons, cyclones getting stronger, few countries will be more affected by a warmer planet than India," Mr. Obama said. "The United States recognizes our part in creating this problem, so we're leading the global effort to combat it. And today, I can say that America's carbon pollution is near its lowest level in almost two decades."
"We'll continue to help India deal with the impacts of climate change because you shouldn't have to bear that burden alone," he added. "And as we keep working for a strong global agreement on climate change, it's young people like you who have to speak up so we protect this planet for your generation."
© 2015, The New York Times News Service