© Getty Images
Coventry - who were playing at Northampton Town's ground as financial issues prevent them from playing at the Ricoh Arena - raced into a three goal lead before Bristol City came back into the match after half time.
Coventry took the lead once more straight away, before Marvin Elliott levelled the scores with just five minutes remaining, but the Sky Blues scored a dramatic late winner.
Andy Webster started his first game for Coventry while Jay Emmanuel-Thomas, a summer signing from Championship side Ipswich Town, started for Bristol City.
Leon Clarke opened the scoring in the 27th minute from the penalty spot after Aden Flint fouled Callum Wilson.
Wilson then found himself on the scoresheet when he curled home a delightful finish before Billy Daniels scored his first senior goal to give the home side a three-goal advantage.
Sam Baldock gave the travelling Bristol City fans something to cheer with a 55th-minute goal and Jay Emmanuel-Thomas scored another just seven minutes later.
The comeback was complete as Baldock scored his second goal of the game with 15 minutes remaining, but Wilson scored yet again to give Coventry the lead almost immediately.
Marvin Elliott looked to have rescued a point for his side with an 85th minute equaliser, but 19-year-old Billy Daniels scored a dramatic late winner to give the financially-stricken club an incredible win.