Michael Duffy – who scored Derry’s last goal in the 60th minute of the narrow 3-2 home win against Athlone on 4 April last – ended City’s goal drought of 180 minutes when he got on the end of a Jon Paul McGovern cross to head home a minute before the break.
UCD went ahead in the 35th minute through Robbie Benson.
Earlier, Patrick McEleney spurned the chance to put the home side in front when he missed from the penalty spot in the 11th minute after he was tripped in the box by Kavanagh.
The visitors started the brighter in the second half and it took a great save by Gerard Doherty to keep City on level terms.
McGovern went close on two occasions before UCD keeper O’Donnell pulled off a good save from McEleney who had been brilliantly set up by Duffy.
Derry City: Doherty, Byrne, Collins, Elebert, Jarvis, Duffy, P McEleney (Foy 78), McGovern (Stewart 71), Ventre, E Curran, R Curran.
Substitutes: Gallagher, Barry, McBride, T McNamee.
UCD: O’Donnell, Boyle, Creevy, Douglas, Langry, Benson, Crowe, Kavanagh, Mulhall, Belhourt, Morrison.
Substitutes: Burke, Coyne, Matthews, McGinley, O’Halloran, Ryan, Scott.
Referee: Robert Harvey.
Airtricity Premier Division
Bray Wanderers (Scully 65) 1 Dundalk 0
Cork City (Dennehy pen 53) 1 Bohemians (Byrne 57) 1
Drogheda United (Brennan pen 22, Hughes 87) 2 Shamrock Rovers (Finn 10, Zayed 52, Kilduff 57) 3
Limerick FC 0 Sligo Rovers (O’Connor 3, Greene 89, Conneely 90+3) 1
St Patrick’s Athletic (Chambers 11, Fagan 41, 77, Lynch 75) 4 Athlone Town 0
Airtrcity Division One
Waterford United (Barrett 17, Doherty 44) 2 Finn Harp 0
Wexford Youths 0 Shelbourne 0