The Cote d'Ivoire striker scored with 11 minutes remaining to give the home side victory at the Stadio Olimpico.
Gervinho scored as Roma moved into the semifinals of the Coppa Italia with a 1-0 win over Juventus.
The capital club, which was beaten 3-0 by Juve in Serie A earlier this month, dictated play for much of a scrappy encounter and was rewarded with a victory that keeps alive its hopes of avenging a defeat to Lazio in last year's final.
Gervinho was the hero on the night, as he struck 11 minutes from time with a superb backheeled volley to condemn the Bianconeri to a first domestic loss since a 4-2 defeat to Fiorentina on Oct. 20.
Roma was fortunate not to be reduced to 10 men after 14 minutes when the referee elected only to caution last defender Mehdi Benatia for a foul on Sebastian Giovinco.
The hosts enjoyed the better of the first half without creating any real goalscoring opportunities, with veteran playmaker Francesco Totti going closest just after the half-hour mark as he sent a left-footed volley wide.
Juve looked to have taken the lead a minute into the second half when Federico Peluso headed in at the far post, only for the linesman to rule that the ball had gone out of play in the buildup.
Alessandro Florenzi then went close with a header for Rudi Garcia's men, before the 75th minute introduction of midfielder Miralem Pjanic proved decisive.
The Bosnia-Herzegovina international needed just four minutes to make an impact, surging into the penalty area before laying the ball off for Kevin Strootman, whose near-post cross was turned home in stunning fashion by Gervinho.
Juve failed to mount any sort of revival and although Pjanic wasted a chance to add a second in injury time, Roma held on to progress to the semifinals.