Two goals from Mark Surgenor and one from 15-year-old substitute Matthew Shevlin saw Ballymena secure their first Premiership win in nine outings.
Midfielder Surgenor scored his first with a right-foot half-volley in the 21st minute after Tony Kane had played the ball down the left channel.
Surgenor then rifled home from inside the box after meeting a clever lay-off from Darren Boyce after 35 minutes.
Shevlin netted the rebound after Stefan McCusker had fumbled a Kane free-kick.
United began the game seeking their first victory since they defeated derby rivals on 20 September, while the Mallards had accumulated 10 points from their last six matches.
Early in the game, Allan Jenkins saw his header parried by McCusker and the midfielder then hit the post with the rebound.
Jason McCartney fired wide after latching onto Johnny Lafferty's pass on the left, before Surgenor's two goals put the hosts in charge.
After the break, McCartney's low drive was tipped round the post by Dwayne Nelson and Liam McMenamin hooked an effort off-target.
At the other end, Boyce headed wide from a Matthew Tipton cross, but Shevlin's 85th-minute goal made the points safe and gave Glenn Ferguson's side a morale boost ahead of next month's League Cup semi-final between the sides.