STORY: The Mass was attended by Ivan Fedorov, the mayor of Melitopol, who was detained by Russian forces last month and later freed in a prisoner exchange.
Italian Cardinal Giovanni Battista Re replaced the pope as the main celebrant at the service, which involved a procession in near-total darkness up the central nave of Christendom's largest church.
The pope departed from his prepared text to acknowledge the presence of Fedorov, his family and three Ukrainian parliamentarians sitting in the front. He spoke of the "darkness of war, of cruelty".
"All of us pray, for you and with you. We pray because there is so much suffering. We can only give you our company, our prayers and say to you 'courage, we accompany you," Francis said.
He ended by saying "Christ is risen" in Ukrainian.
The Vatican said Francis met privately with the Ukrainian delegation before the Mass.