It was hardly as clean as the Celtics would have liked. But it’s wins themselves and not style points that matter to the Celtics, who captured their fifth straight victory Sunday with a 121-113 final over the Raptors up in Toronto.

The win, which was powered by a team-leading 30 points from Jaylen Brown, appeared in doubt when the Celtics went cold in the second half on the way to the Green blowing what was at one point a 23-point lead in the second half.

Down 102-99 in the fourth quarter, the Celtics overcame the second-half struggles by scoring 22 of the game’s final 33 points in the fourth quarter of play. And it was a strong finish from the Celtics’ Derrick White late, as White had direct involvement as either the scorer or the assist man on 10 of their final 22 points.

Boston’s near-collapse in the fourth quarter was actually the club’s first brush with danger in a hot minute (since their win over the Knicks last week), as the Celtics went wire-to-wire over both the Wizards and Lakers leading into Sunday’s game.

In addition to Brown’s 30-point outing, as well as White’s 27-point performance headlined by his six makes from three-point range, the Celtics got a boost with a double-double from center Neemias Queta (11 points and 11 rebounds).

As a team, the Celtics had a strong performance from beyond the arc, with makes on 20 of their 47 three-point attempts (42.6 percent). It’s tied for their fifth-best single-game performance from downtown this season.

Brandon Ingram led the way on the scoring front for the Raptors, with 30 points on 11-for-20 shooting, along with four rebounds and three assists.

With the win, the Celtics jumped Toronto for the third-best record in the Eastern Conference. They’re also now just 2.5 games behind the Knicks for the second-best record in the East, and a mere four games behind the East-leading Pistons.

The Celtics are back in action Dec. 11 against the Bucks.