Jason Byrne's rich vein of form continued, taking his tally to 12 this season as Bray edged out UCD in a great game at the Carlisle Grounds.
The striker made it eight goals in his last five league games with one in each period against the Students.
Danny Ledwith drew UCD level with a free-kick but John Mulroy's injury-time score sealed the points.
Bray took a 17th-minute lead. Darren Quigley's quick throw found Mulroy and he played Adam Hanlon clear to cut back for Byrne.
But 'College equalised 10 minutes later as Ledwith's free-kick from 25 yards caught out Quigley. Byrne made it 2-1 in the 68th minute, the 34-year-old toe-poking in off the far post.
UCD almost earned a point in the 93rd minute but sub Gary Burke placed his shot wide from 14 yards with just Darren Quigley to beat after the ball ricocheted into his path.
Straight away, Bray attacked and Waters got in from the left wing to square for Mulroy to tap in between two sliding defenders.
Bray -- Quigley; Webster, Sweeney, O'Connor, Knight; Zambra; Mulroy, Houston (Massey 76); Waters, Hanlon; Byrne.
UCD -- McGinley; Ledwith, O'Connor, Leahy, Nangle; Corry, O'Connor, Benson; McNelis (Langtry 62), Clarke (Lyons 62); Rusk (Burke 86).
Ref -- A Buttimer (Limerick).