The win guarantees the Irish province a home semi-final should they win their URC quarter-final which will also be in Belfast.
The visitors were brighter from the outset and after Duhan van der Merwe’s touch let him down after hacking on over the Ulster line, Darcy Graham scored for Edinburgh after seven minutes when the Scots ran back a dropped high kick by Ulster, Emiliano Boffelli added the conversion.
Then on 25 minutes, Ulster struck back with a stunning try. From a lineout, the Irish province put the ball through the hands and after Craig Gilroy had burst through the middle, Jacob Stockdale and Rob Baloucoune combined before Baloucoune’s return pass put Stockdale over the line.
Cooney missed the tricky conversion and Edinburgh still led 7-5 until he bisected the posts with a 37th-minute penalty to put the hosts ahead for the first time.
Cooney then stretched this to 11-7 with the clock in red with another penalty.
The second half was barely a minute old when Cooney intercepted Blair Kinghorn’s pass to run in from just inside his own half. He converted his own score and Ulster now led 18-7.
That became 25-7 after 65 minutes when Nick Timoney barrelled over from close to the Edinburgh line following a yellow card being shown to Glen Young in the previous phase. Cooney slotted the straightforward conversion to take his points haul to 15.
Edinburgh’s Charlie Savala then had a score ruled out just before WP Nel crashed over for a converted try.
However, Cooney closed business for the evening with a 78th-minute penalty.