The visit by Francis has been shadowed by the controversy over migrant arrivals in Europe, and his plea to welcome people puts him at odds with most EU governments in countries including Italy and France.
But the centrepiece of the visit was the mass at Marseille's main stadium the Velodrome -- usually the venue for rugby or football matches.
The Pope received huge cheers as he closed the service, asking the faithful in French to "pray for me, it's a difficult job" -- his favoured parting line.
Marseille archbishop Jean-Marc Aveline declared that the pope had been "baptised as a citizen of Marseille," again drawing an ovation from the crowd.
The pontiff's visit to the Velodrome was "as if you went to every Marseille person's home," Aveline added.
Francis had entered the stadium aboard his popemobile after being driven at walking pace in the open-top vehicle through the streets of the city to receive the greetings of residents waving Vatican and French flags.
Clutches of black- or white-robed priests and nuns were scattered through the crowds during the service, while volunteers distributed communion wafers.
Fans of the much-loved Olympique de Marseille football team lifted up a giant banner of a smiling Francis and the hilltop basilica of Notre-Dame-de-la-Garde, which he visited on Friday.
According to local authorities there were 50,000 people in the stadium while 100,000 had lined the streets during the pope's tour.
- 'Graveyard of dignity' -
The pontiff, 86, who looked sprightly despite often using a wheelchair between engagements, meanwhile showed no fear in entering the fraught debate on migrants.
"Those who risk their lives at sea do not invade, they look for welcome," Francis said in a speech earlier Saturday, closing a conference of bishops and young people from around the Mediterranean.
Migration is "a reality of our times, a process that involves three continents around the Mediterranean and that must be governed with wise foresight, including a European response," he added.
Noting the risk to the lives of migrants if they are not taken to safety, he warned against turning "the Mediterranean, the mare nostrum, from the cradle of civilisation into the mare mortuum, the graveyard of dignity".
Worshippers cheered when Aveline thanked the pontiff for his "powerful and courageous words," in an apparent rebuke to French President Emmanuel Macron, present in the stadium, whose government plans to toughen up controls on migrants.
The pope's forceful interventions came as the migration debate has been stoked by mass arrivals on the Italian island of Lampedusa earlier this month.
A French presidential official said that Macron and the pope had discussed migration in bilateral talks earlier. "France has nothing to be embarrassed about, it's a country of welcome and integration," the official said.
Francis and the president were set to speak again at Marseille airport before the pontiff's departure.
- 'Pushed aside' -
Some politicians on the left have criticised Macron's decision to attend Saturday's mass as an infringement of state secularism.
Others on the right have attacked Francis for interfering in domestic politics.
The pontiff did nothing Saturday to dodge such allegations, appearing to weigh in on two of Macron's projects -- assisted dying and inscribing the right to abortion in the constitution.
Old people risk being "pushed aside, under the false pretences of a supposedly dignified and 'sweet' death that is more 'salty' than the waters of the sea," Francis warned.
He also spoke of "unborn children, rejected in the name of a false right to progress, which is instead a retreat into the selfish needs of the individual."
The French presidential official said that Macron discussed the "methodology" and the "calendar" of a bill on the end of life that the government wants to present to parliament in the next weeks.
Francis's messages may have less resonance given Catholicism's long decline in France.
Fewer than a third of people still say they are Catholic, and only a small fraction of those regularly attend mass.
The country's religious heritage nevertheless still has enormous weight, with Macron showing off progress in restoring the fire-ravaged Notre-Dame cathedral in central Paris to Britain's King Charles III earlier this week.