© Getty Images
In a limp first half, the game's first chance did not arrive until after 20 minutes, and it was Nice who almost went ahead when Dario Cvitanich lashed his shot onto the crossbar.
The hosts threatened again just before the break as Cvitanich looked to turn provider when he found Carlos Eduardo in space, but his long-range effort was saved by Johann Carrasso in the centre of goal.
After a quiet opening period, Metz were presented with a perfect chance to go in front just after the break, but it was wasted by Modibo Maiga, who headed high and wide to the right after Kevin Lejeune's cross.
It looked as though the fixture would be heading for a draw, only for Bosetti to turn the game on its head, as he produced a deft finish to win the encounter with one of the last kicks of the game.