The pontiff said that it is not Christian to shut out immigrants, urging nations to welcome people whose lives had been "watered down" by poverty, injustice and exploitation.
Pope Francis highlighted the plight of vulnerable immigrants on Thursday and robustly defended a bishop accused of covering up sexual abuse at the end of a visit to Chile overshadowed by controversy.
In the northern border region of Iquique, which he said was "the land of dreams" for so many, the pope hit out at human traffickers and others who seek to take advantage of helpless immigrants.
"Let us be attentive to those who profit from the irregular status of many immigrants who don't know the language or who don't have their papers 'in order'," Francis told a colourful congregation of around 50,000 at an open-air mass on Iquique's sprawling Lobito beach.
TRT World's Ben Said reports.
Sexual abuse allegations
The 81-year-old pontiff has confronted sensitive issues at every turn since he began his visit on Monday, offering an apology to victims of priestly sexual abuse, praying with survivors of Augusto Pinochet's brutal dictatorship, and calling for protection of the rights of Chile's persecuted indigenous communities.
The sex abuse issue dogged him almost to the altar as he prepared to celebrate mass on Thursday.
Chit-chatting about the visit with journalists as he stepped down from his Popemobile, Francis' mood turned serious when tackled about his support for the controversial bishop.
"The day they bring me proof against Bishop Barros, then I will speak," the pope said in response to a journalist's question about the 61-year-old, appointed by Francis in 2015 despite being accused of covering up another priest's abuse of boys.
"There is not a single piece of proof against him. Everything is slander. Is this clear?" the pope said before walking off to prepare for Mass.
Bishop Juan Barros was attending the ceremony along with hundreds of other bishops and clergy. Barros has been a conspicuous presence at both of the pope's previous open-air masses and his meeting with clergy at the Santiago cathedral.
Days before the start of the visit on Monday, the US-based NGO Bishop Accountability said that almost 80 members of the Roman Catholic clergy had been accused of sexually abusing children in Chile since 2000.
Local Catholic groups in Barros' southern diocese of Osorno are demanding that Francis remove him for his ties to one of the highest-profile abusers, disgraced paedophile priest Fernando Karadima.
Barros "is a liar, a delinquent, who has amnesia after covering up for Karadima. He has covered-up abuses and should be in jail or at least dismissed," said Juan Carlos Cruz, one of Karadima's victims.
Demonstrations against Church sex abuse scandals and attacks on churches marked the opening days of his visit to Chile.
The pope celebrated Mass in a restive southern region on Wednesday, denouncing the use of violence in the struggle for indigenous rights, only hours after assailants firebombed churches and other targets.
The state has long been accused of persecuting the Mapuche people, who centuries ago controlled vast areas of Chile but have since been marginalised.
At the pope's first public Mass in Santiago on Tuesday, he faced protests over the church's handling of decades of sexual abuse by the clergy.
Scuffles broke out between riot police and demonstrators near O'Higgins Park, and police used water cannons on protesters. More than 50 people were arrested, authorities said
Later, the pope met privately with a small group of people sexually abused by priests, after he publicly asked for forgiveness.
After Thursday's Mass in Lobito beach, the pope leaves Chile for a four-day visit to Peru, the final leg of his South American trip that is set to include stops in the cities of Puerto Maldonado, Trujillo and Lima.