Trailing 2-0 at half-time with goals from Sam Collier and Stephen Davis, Didcot fell further behind to Daniel Barry's team on 58 minutes after Adam Bruce finished from a tight angle.
But Mark Janes converted from the penalty spot on 72 minutes and when Jimmy Deabill struck four minutes later nerves began to jangle around Alfredian Park.
Josh Dutton-Black tucked in the equaliser with 10 minutes remaining after Andy Ballard's header had bounced back off the crossbar.
And the comeback was complete when Deabill headed in his second on 92 minutes and Didcot's fourth.
The Emirates FA Cup
Preliminary Round
Friday 28 August
Winners receive £1950 from prize fund
Ryan Cox headed a dramatic injury-time winner as AFC Liverpool produced a fine comeback of their own to beat Radcliffe Borough 3-2 to win a preliminary round tie for the first time in their short history.
After a goalless first half, Liverpool found themselves 2-0 down shortly after the restart with Thomas Hulme at the double.
But Paul Moore's team showed they have goals in them having beaten Chadderton 9-2 in the previous round and got back into the tie on 57 minutes through Cox.
Francis Barry then levelled for Liverpool on 68 minutes before Cox completed the comeback with his second and the home side's third.
Sittingbourne bypassed a potential banana skin to win 2-1 at Seven Acre & Sidcup.
Left-back Conrad Lee opened the scoring for the visitors, two tiers above Seven Acre in the English football pyramid, bursting forwards from deep before curling in.
But Anthony Fenech equalised before the interval, latching onto Chris Hubbard's through pass before stroking home.
With the clock ticking down, Hicham Akhazzan climbed off the bench to blast in the winner after good work from Fred Obasa.
Swindon Supermarine were away winners too, beating Sholing 4-2 at the Silverlake Arena.
The home side edged ahead on eight minutes when Jamie Bulpitt played in Daniel Mason to score.
But by half-time Supermarine had turned the tie on its head through Chris Taylor and Jacob Davidge.
And they opened up a two-goal cushion with a third on the hour from substitute Ashley Edenborough after a long period of pressure.
Sholing grabbed a lifeline when Mason struck again, but, as they pushed for an equaliser, the visitors broke clear and Davidge chipped in number four.
St Ives Town and Norwich United will replay on Wednesday night, after a 1-1 draw.
Danny Watson opened the scoring for St Ives, but he was sent off for receiving two yellow cards barely a minute apart to give the visitors some hope.
And, after a barrage of pressure in the final 15 minutes, Norwich got their reward when Matthew Blake fired in from the edge of the box.