Four goals in a 24-minute second-half purple patch saw them avoid an upset at the One Call Stadium and book a visit to Anfield.
Both of these clubs played Liverpool in this competition last year and were desperate for a rematch after a 1-1 draw at Boundary Park set up this second-round replay.
Mansfield even took the lead against their League One visitors through Ross Dyer after 12 minutes.
But the Stags fell apart in the second half and ended the game with nine men after John Dempster was red-carded for an 81st-minute handball in the box and then star winger Sam Clucas was taken to hospital near the end with an ankle injury with all three subs used.
While Mansfield were left to think about what might have been, Oldham were looking forward and Johnson said: "It's a super prize to be going to Anfield. It's for the boys. Not too many of them were here last season when we last played them.
"When you play for a small club you get certain big moments in your career - and this is one of them.
"The first half wasn't great. We huffed and puffed and didn't have any quality.
"But that was a monumental performance from the boys in the second half and I am so pleased for them.
"Our keeper made a fantastic save to stop it going to 2-0 and then we went down the other end and Danny (Philliskirk) scored a great free-kick. He's got that in his locker. He is a good player who can produce that bit of individual brilliance.
"That set us off and we looked comfortable after that. The game opened up and we have fit, young, hungry mobile players and we saw it out convincingly and we could have gone on and had five or six goals."
Dyer had made the breakthrough after 12 minutes as he met Lindon Meikle's powerful by-line cross with a close-range header and Clucas fired another chance just wide for the underdogs.
But Oldham were dominating possession and keeping the Stags' defence busy with Dempster making superb blocks to deny Mike Petrasso and Jonson Clarke-Harris, the former seeing another effort pass inches wide.
The turning point of the night was when Latics keeper Mark Oxley got down to his left to somehow tip away a low Meikle finish that was destined for just inside the far post after 52 minutes.
Within five minutes Oldham opened their account in style as Philliskirk crashed a superb free-kick into the top right corner from a central position just outside the box.
The screw turned further as Petrasso set up Clarke-Harris to his left for a low finish five minutes later.
The third goal after 62 minutes killed off any hopes Mansfield had of a comeback as they allowed Matteo Lanzoni to run in and bury a free header from a Philliskirk corner.
There was controversy after 81 minutes as Dempster threw himself into the path of a powerful close-range Clarke-Harris shot and the referee decided he had deliberately got his hand in the way and sent him off.
Adam Rooney sent Alan Marriott the wrong way and Oldham were home and dry.