Elliott Frear had put Adrian Pennock's side ahead shortly before the break, but Luke George levelled the tie just after the hour mark and it appeared that Chester would hold on for a point until O'Connor netted his late winner.
Woking, who went into their game at Macclesfield Town in third place, lost 2-1 despite Joey Jones's late goal as Kristian Dennis's sixth goal of the season and a Neill Byrne effort sealed a win for the Silkmen.
Gateshead also lost as a Moses Ademola brace and a further strike from Louis Dennis saw them go down 3-0 away at Bromley, while a 95th-minute winner from Sam Heathcote saw Altrincham beat Cheltenham Town 2-1 at Moss Lane, meaning that Forest Green Rovers were the only side in the top five to win.
At the other end of the table, Kidderminster Harriers' search for a win goes on as a Kenny Davis penalty just before half time was enough to give Braintree Town all three points in a bad-tempered affair that saw both sides reduced to 10 men.
Southport put distance between themselves and Kidderminster as they held Dover Athletic to a goalless draw, while Halifax Town mounted a late comeback against Aldershot Town as Danny Hattersley and David Brooks stuck in the final half-hour, but Neil Aspin's side still lost 3-2.
Charlie MacDonald netted his first goal for Boreham Wood, but still finished on the losing side as strikes from Omar Bogle and Nathan Arnold and a Scott Doe own goal gave Grimsby Town a much-needed win.
At Plainmoor, Exodus Geohaghon cancelled out an early Liam Dickinson penalty as Torquay United and Guiseley shared the spoils in a 1-1 draw, while Lincoln City and Wrexham also had to settle for a point a piece as James Gray and Matt Rhead both netted at Sincil Bank.
Results in full (half-time scores in brackets): Aldershot Town 3-2 Halifax Town (2-0), Altrincham 2-1 Cheltenham Town (0-0), Barrow 1-0 Eastleigh (1-0), Boreham Wood 1-3 Grimsby Town (0-1), Bromley 3-0 Gateshead (0-0), Chester FC 1-2 Forest Green Rovers (0-1), Kidderminster Harriers 0-1 Braintree Town (0-1), Lincoln City 1-1 Wrexham (0-0), Macclesfield Town 2-1 Woking (1-0), Southport 0-0 Dover Athletic (0-0), Torquay United 1-1 Guiseley (1-1)