Coupe de France Wrap: Monaco edge through
The former Manchester United and Tottenham forward came off the bench midway through the second half and notched six minutes from the end of extra time.
Nice faced an uphill battle when Timothee Kolodziejczak was shown a straight red card three minutes after the break but the visitors, winners of the competition in 1991, left it late to seal their progress.
Ligue 1 Guingamp advanced to the last eight by avoiding an upset against amateur side Fa Ile Rousse Monticello.
The visitors broke the deadlock five minutes before half-time through Gregory Cerdan, with Moustapha Diallo wrapping up a 2-0 win 12 minutes into the second half.
Elsewhere, Rennes squeezed past Ligue 2 Auxerre 1-0 thanks to a first-half Foued Kadir effort.
Auxerre's quest for an equaliser was thwarted when Yann Boe-Kane saw red for a second booking 10 minutes after half-time.
The quarter-final will have representation from a fourth-tier side after Moulins defeated nine-man Sete 3-1.
Sete, one division below their opponents, took an early lead through Christophe Rouve but he was sent off after Sebastien Da Silva's brace had turned the game on its head.
Things got worse for the visitors in stoppage time when Xavier Burdin put through his own net and Kaoussou Diakhate followed Rouve down the tunnel.