A migrant who climbed four stories up a building to rescue a child dangling from a balcony has been offered a new start in France.

President Emmanuel Macron met with 22-year-old Mamoudou Gassama on Monday to thank him personally after videos capturing the spectacular rescue went viral on social media over the weekend.

The footage shows Gassama, who is originally from Mali, pulling himself up from one balcony to the next to reach the child.

Two people in the neighboring unit tried to hold onto the child as onlookers cheered Gassama on as he scaled the Paris building's façade on Saturday.

Le Parisien newspaper reported that Gassama was walking by when he saw a gathering in front of the building and leapt to action.

“I did it because it was a child,” the paper quoted him saying. “I climbed. … Thank God I saved him.”