Lee Molyneux snatched victory for the visitors in the third minute of stoppage time to move them five points clear of the League Two relegation zone.
What came before was instantly forgettable as both sides struggled to get into their stride on a bobbly pitch, Stuart Lewis coming closest when he hit a post.
"That late goal was an absolute kick in the teeth," Ainsworth said. "I didn't think either team deserved to win that game, but we had the better chances if I'm honest - we just couldn't stick them away.
"I think they've then had about one shot on target and they've scored with it so there wasn't great deal between the teams.
"The ball has bounced quite high off the pitch and was in the air a lot so there wasn't a great deal of quality out there.
"One little error from a set-play has cost us right at the end, but on another day we take our chances in the game, it happens.
"We just need to pick ourselves up quick because we've got a long trip up to Morecambe on Monday, but it wasn't a great game at all and had 0-0 written all over it until they smashed one in with 30 seconds to go."