Replacements: Liam Hyland, Adam Clarkin, Daniel Leavy, Jamie Glynn, David McSharry.
Replacements: Paddy Hogan, Adam Howard, Alan Trenier, Fergal Lawlor, Steve Crosbie.
It did not take long for Paul Cunningham's Belvedere outfit to respond. Luke McGrath's Leinster colleague Leo Auva'a spun the ball to Aidan Wynne who drew the last UCD defender before releasing John Kennedy for an eighth minute try.
With Josh Glynn injured, the kicking duties fell to Shaun Berne who was off target with the conversion.
A brace of penalties by Thornton on 13 and 17 minutes saw UCD lead 13-5 and it was to get better for the students.
Almost directly from the restart, scrum half McGrath's sniping run sent Andrew Boyle away for his second try of the season. Thornton split the posts from the touchline with the conversion, making it 20-5 with 20 minutes played.
'Belvo's impressive scrum half Aaron Sheehan then stepped up for the visitors, spreading the play wide for winger Conor Power to take advantage of an overlap and touch down. Berne converted this time.
However, the 15-point margin was restored just on half-time. UCD won a 'Belvo lineout and after Barry Daly made a break down the narrow side, he popped the ball up to the onrushing Eoin Joyce who touched down for a try which Thornton again converted for 27-12.
Cunningham introduced Ireland Under-20 out-half Steve Crosbie at the break, with Berne switching to centre, while Connacht centre David McSharry, who is working his way back from injury, got a run-out for UCD.
Within minutes of the restart Berne almost took advantage of a loose UCD pass but he knocked on what would have almost certainly been a try-scoring interception. At the other end, Thornton was off target with a penalty.
'Belvo full-back and captain Daniel Riordan then touched down after a Crosbie cross-field kick was not gathered by Boyle or Daly under pressure from Mark Corballis. The ball fell for Riordan who gathered to touch down with Berne adding the extras.
UCD managed to steady themselves with a Thornton penalty and Boyle and Daly made up for the earlier misjudgment when they combined to force Corballis out of play a metre from the line.
But with Riordan kicking for the corner shortly afterwards, it was fitting that the skipper finished the move for 'Belvo's bonus point try just before the 70-minute mark. Berne converted to leave just four points between the sides - 30-26.
McSharry looked to have gone over for a try only for referee Olly Hodges to bring play back for a UCD scrum in front of the posts, but 'Belvo got the push on and cleared.
Thornton crucially stretched the home side's lead to seven as the game entered the final minutes, and a knock on at the death ended what could have been another grandstand finish for 'Belvo.
Referee: Olly Hodges (IRFU)