The unbeaten hosts ended a run of four straight draws which had threatened to undermine their title hopes with a victory which moved them three points behind Serie A leaders Juventus.
Maicon put the capital club ahead in the seventh minute following fine skill from Gervinho, but Juan Vargas levelled before half-time.
But Roma got the winner in the 67th minute. Gervinho was again involved, the former Arsenal man's corner picking out Mattia Destro to score at the far post.
Roma had Miralem Pjanic sent off in the 88th minute, but it did not prove costly.
The home side, without a league win since the last of their 11 in a row at the end of October, got off to a flying start.
Gervinho beat Nenad Tomovic and got to the byline before pulling back a low cross to Alessandro Florenzi, who laid the ball off for Maicon to tap home.
Florenzi went for goal himself from the edge of the area shortly after, but his shot was saved by Norberto Neto.
The visiting goalkeeper was tested again by a Daniele De Rossi header, while Pjanic fired wide as the hosts continued to dominate.
Fiorentina created their first opening in the 21st minute, Giuseppe Rossi sweeping past De Rossi and seeing his shot deflected behind.
Roma should have doubled their lead five minutes later, though, when Adem Ljajic's through-ball sent Gervinho clear, but the forward could not take advantage of the opportunity.
Instead La Viola equalised three minutes later as Vargas slid home Nenad Tomovic's pull-back.
Fiorentina tails were up and Rossi lashed a shot over, while Juan Cuadrado also fired high from long rage.
Roma had another chance just before the break, though, as Mehdi Benatia headed a Pjanic corner just over.
Fiorentina might have gone ahead four minutes into the second half, but no one could get a touch on Manuel Pasqual's low cross which fizzed across the face of goal.
At the other end Gervinho forced a save from Neto before visiting midfielder Alberto Aquilani almost netted against his old club only to shoot narrowly over.
Neto had to be alert to save from Ljajic, but he was saved by his post a minute later when Maicon picked out Kevin Strootman and the Dutchman's shot came back off the upright.
And Roma regained the lead in the 67th minute as Destro fired home following Gervinho's deep corner.
Benatia almost added a third, but his header from a Pjanic corner brushed the far post.
Fiorentina's hopes were boosted by Roma were reduced to 10 men following Pjanic's late dismissal for a second yellow card, but Rossi's shot which was cleared away by Leandro Castan was as close as they came.