ROME - Roma secured direct entry into the Champions League group phase with a 2-1 win over Lazio in a heated Serie A derby Monday that featured three late goals.

French centre back Mapou Yanga-Mbiwa decided the match with a header following a free kick in the 85th minute — his first goal of the season.

Roma had taken the lead in the 73rd when Juan Manuel Iturbe chipped in from within the box, but Lazio substitute Filip Djordjevic equalized in the 82nd with a header.

With one round remaining, second-place Roma moved four points clear of third-place Lazio, which has a three-point advantage over Napoli — its opponent next weekend.

"Complements to the lads," Roma coach Rudi Garcia said. "It wasn't an easy match but we did it. We achieved our goal. ... The church is staying in the centre of the village."

Lazio needs at least a draw at Napoli to secure third and qualify for the final Champions League playoff round, in August.

Juventus already secured its fourth straight title, and also beat Lazio 2-1 in the Italian Cup final last week.

"In (five) days we've lost two matches that we shouldn't have," Lazio coach Stefano Pioli said. "These are tough losses and we've got to show our professionalism and bounce back and do what's required."

Lazio dominated the possession, with 62 per cent to Roma's 37 per cent.

Roma has now won four of its last five matches, following a difficult stretch where it looked like Lazio or Napoli was going to take the lucrative direct Champions League spot.

Roma celebrated as if it had won the league, piling on top of each other with captain Francesco Totti putting on a celebratory T-shirt.

"This was a huge achievement," Roma midfielder Daniele De Rossi said. "This success should be a starting point for us."

Despite the presence of 1,700 police officers in and around the stadium, two fans were bloodied in knife attacks outside the stadium before kickoff, the ANSA news agency reported.

There were also reports of clashes between Lazio supporters and police outside the stadium after the match, with tear gas used.

In a sign of protest after insults from the club's American president, James Pallotta, Roma fans didn't produce any pre-match choreography. Instead, the hard-core "ultra" fans in the southern curve of the stadium held aloft a banner that read: "No choreography today for our dignity: a real president doesn't insult his people."

Lazio, which was the home side, had the best chance of the half five minutes in when Miroslav Klose missed the target from close range.

Lazio controlled play early on but for the most part the first half was a tense and physical affair with both sides resorting to counterattacks. Nicola Rizzoli, the referee who officiated last year's World Cup final, handed out four yellow cards — one to Roma and three to Lazio — before halftime.

By the end, there were eight yellows.

Lazio fullback Dusan Basta had a good look at the goal early in the second half but his angled attempt went wide.

Ibarbo replaced Totti on the hour mark and had a great look at the goal 10 minutes later but sent the ball wide with one touch. A few minutes later, Ibarbo carried deep into Lazio's area and crossed to Iturbe for the first goal.

Lazio's equalizer was a textbook set piece. After a free kick from Felipe Anderson, Klose from the far post headed it back toward Djordjevic to send it in with a header himself.

The winner followed a free kick from substitute Miralem Pjanic that saw Roma place several players offside — but not Yanga-Mbiwa — and the defender headed it in near the far post.