Francis, who has said he wants to make concern for the poor a hallmark of his papacy, will visit the Manguinhos slum in Rio de Janeiro on the fourth day of his July 22-29 trip to the world's largest Catholic country.
Manguinhos is one of Rio's most visible favelas, wedged between a busy highway and a former oil refinery and near the main airport and large military bases.
The shantytown, which the pope will visit on July 25, had a long history of drug-related violence, but a police occupation late last year kicked out many of the drug and gun traffickers.
Manguinhos, home to about 35,000 poor people, is one of the communities that have been part of a community policing operation that has reduced violence in the shantytowns of Rio de Janeiro.
The pope will also meet young prisoners who will be brought to the archbishop's residence for the occasion.
The main purpose of the trip is for the pope to preside at the Catholic Church's World Day of Youth, an international gathering sometimes dubbed a "Catholic Woodstock" that takes place in a different city every two years.
The World Day of Youth celebrations start on July 23 and end on July 28.
Francis, the first non-European pope in 1,300 years on, arrives on the afternoon of July 22 and will rest the next day to overcome jet lag, according to the official programme of the trip released by the Vatican.
On July 24, he will fly by helicopter to the city of Aparecida, about 240 km (150 miles) southwest of Rio de Janeiro, to visit the national shrine of Our Lady of Aparecida, whom the Church honours at the patroness of Brazil.
That evening he visits a hospital in Rio that treats AIDS patients.
The pope's participation in World Youth Day events starts on the evening of July 25 in Rio's famed Copacabana Beach area and culminates with a huge open-air Mass in the Guaratiba area of the city on July 28.
During the trip he will also address Brazil's political and business leaders.
The trip is expected to be the only one abroad for the pope this year. The former Cardinal Jorge Bergoglio of Buenos Aires is expected to visit his homeland early next year.
He is expected to travel to the central Italian city of Assisi, birthplace of St. Francis, whose name Bergoglio adopted when elected pope on March 13.
(Additional reporting by Alonso Soto in Brasilia; Editing by Jon Hemming)