Brazil and the rest of the region face dangerously high rates of drug abuse and traffickers must "reflect on the grave harm they are inflicting on countless young people and on adults from every level of society," Benedict said.
"God will call you to account for your deeds," he said before a cheering crowd of 6,000 on a sprawling lawn outside the "Fazenda de Esperanca," or "Farm of Hope," a drug treatment center founded by a Franciscan friar.
Brazil is the world's second-largest consumer of cocaine, after the United States, according to the State Department, and big cities across Latin America's largest nation are plagued with drug violence.
While surveys show cocaine use has been relatively stable in Brazil for years, drug-related violence is a huge problem, driven by gangs that control street-corner dealing and the transshipment of drugs to Europe and the United States from elsewhere in South America.
In Rio de Janeiro's teeming slums, gangs recruit children and engage in near-daily shootouts with police that frequently kill bystanders.
The violence is endemic in other Latin American countries, including Colombia, and Caribbean nations. In Mexico, gangs battling over billion-dollar smuggling routes into the United States leave a daily body count from beheadings, grenade attacks and execution-style killings.
The treatment center the pope visited claims an 80 percent success rate, giving addicts spiritual guidance as they milk cows, tend apple orchards and work as beekeepers.
Benedict donated $100,000 to the treatment center and told more than 1,500 recovering addicts wearing white shirts with yellow sleeves, representing the Vatican's flag, that they must become "ambassadors of hope."
"The Lord has given you this opportunity for physical and spiritual recovery, so vital for you and your families," the pope said. "In turn, society expects you to spread this precious gift of health among your friends and all the members of the community."
Addicts who listened to the pope said his visit was important because Brazilian drug users are often ostracized and left to beg on the streets for drug money.
"We are excluded from society, but we are the ones the pope is coming to see," said Diego Cleto, a 19-year-old who started taking drugs at age 13.
But some doubted whether the pope's message to traffickers will have any impact.
"What the pope said is important for drug users, but religion doesn't matter to the dealers," said Felipe Kenji, 27, who has been under treatment at the center since December. "They'll only stop selling drugs when they die."
The Guaratingueta treatment center was founded by Friar Hanz Stapel in 1983. There are now 31 similar centers in Brazil and 10 more abroad — in Argentina, Germany, Guatemala, Mexico, Mozambique, Paraguay, the Philippines and Russia.
The center is near the shrine city of Aparecida, where Benedict on Sunday will open a Latin American and Caribbean bishops' conference aimed at reversing the erosion of the church in the region.
Benedict on Friday lamented "difficult times for the church" in Brazil amid "aggressive proselytizing" by born-again Protestant congregations.
Brazil's census shows the percentage of citizens characterizing themselves as Catholics fell to 74 percent in 2000 from 89 percent in 1980, while those calling themselves evangelical Protestants rose to 15 percent from 7 percent.
The pope is expected to map out strategy to combat the church's losses when he opens the bishops' conference in Aparecida, 100 miles east of Sao Paulo.
The small city is home to the mammoth Basilica of Aparecida — as well as the three-foot-tall statue of a black Virgin Mary, called "Our Lady Who Appeared," the patron saint of Brazil.
The statue was pulled from a river in the 18th century by poor fishermen who were not catching any fish, and then caught loads in their nets. Miracles were subsequently attributed to the statue, and so many pilgrims flocked to Aparecida that the church built the basilica and inaugurated it as a shrine in 1955.