You are not permitted to download, save or email this image. Visit image gallery to purchase the image.
The pope also urged Brazil's youth, who have taken part in recent protests showing discontent with the status quo, to keep alive their "sensitivity towards injustice" and be a catalyst in the fight against corruption.
The first Latin American pope, who has rallied the Church on behalf of the poor and who lives more austerely than his predecessors, called for a "culture of solidarity" to replace the "selfishness and individualism" prevailing in modern society.
"No one can remain insensitive to the inequalities that persist in the world," he told residents of Manguinhos, a sprawling shantytown, or favela, of ramshackle brick dwellings that until recently was overrun by violence and controlled by drug lords.
His speech, under rains that have persisted throughout most of his first trip abroad as pope, came halfway through a week-long visit around World Youth Day, a gathering of young Catholics that is expected to attract more than a million faithful to Rio de Janeiro and nearby sites.
Despite the downpours and unusually chilly weather, tens of thousands of rapturous Brazilians and foreign visitors have turned out to welcome the pope. The World Youth Day events are an effort by the Vatican to inspire Catholics at a time when rival denominations, secularism and sexual and financial scandals continue to lead some to abandon the Church.
Brazil, home to the world's biggest population of Catholics with over 120 million faithful, is an apt locale for the pope to remind the world of inequality. A recent decade of economic growth in the country raised incomes for many, but tens of millions of Brazilians still live in poverty or with little more than the basics to get by.
In Manguinhos, Francis, an Argentine known for frequent outings into the slums near Buenos Aires even as a cardinal, smiled and visibly enjoyed the chaotic close contact allowed with residents there. He called for more efforts to end poverty and said authorities must do more than just crack down on the drug trade to ensure opportunities for those at the bottom of the economic ladder.
"Everybody, according to his or her particular opportunities and responsibilities, should be able to make a personal contribution to putting an end to so many social injustices," he said in an address on a muddy, rain-drenched soccer field next to a river smelling of sewer water.
Making the speech after blessing the favela's small chapel and visiting one of its homes on a recently cleaned street, the pope challenged the rich and powerful to use their influence to enact lasting change.
"I would like to make an appeal to those in possession of greater resources, to public authorities and to all people of good will who are working for social justice: never tire of working for a more just world, marked by greater solidarity!" he said.
Reflecting his humble personal style, Francis said he would like to have been able to stop in every Brazilian home "to ask for a glass of cold water, to take a cafezinho, but not a shot of cachaça," a mention of Brazilian rum that drew laughter from the crowd.
Driving in an open popemobile, Francis was surrounded by a throng of residents, some barefoot, and leaned out to kiss a woman and shake extended hands as he entered the slum, where there was a heavy presence of police and military.
The pope praised Brazils efforts over the last decade to reduce poverty in Latin America's largest nation, which last month was rocked by massive protests against corruption, the misuse of public money and the high cost of living.
But he said more needed to be done to bridge the gap between rich and poor at the root of social injustice, in a reference to the police occupation of Rio's slums started last year to "pacify" drug-related violence.
"No amount of 'pacification' will be able to last, nor will harmony and happiness be attained in a society that ignores, pushes to the margins or excludes a part of itself," he said.
Manguinhos, home to about 35,000 poor people, was known locally as "Gaza Strip" for its frequent shootings. It is one of the slums that have been part of a community policing operation that has reduced violence in the shantytowns of Rio de Janeiro.
"In those days, I never knew when I entered the church if I would be alive when I got out," said Father Marcio Queiroz, pastor of the local chapel. "It was like a fruit market but instead of selling fruit on the tables on the street there was guns, crack and other drugs."
At one end of the sports field where Francis spoke hung a huge painting of Archbishop Oscar Romero of San Salvador, who often denounced repression and poverty in his weekly homilies and was murdered by a right-wing death squad in 1980.
Francis has decided to unblock the beatification process for Romero, the penultimate step before Catholic sainthood.
From the slum, Francis traveled to Rio's modern cathedral, where he received a roaring welcome from tens of thousands of young people from his native country who were in Rio for the Catholic jamboree.
On Thursday evening he is to welcome participants in the World Youth Day from a stage on the crescent shaped Copacabana beach. More than one million people are expected for the event.
On Sunday, he presides at the close of World Youth Day in a pasture outside Rio before leaving for Rome that evening.