Tuesday night's result booked the League One leaders a home tie against Chesterfield in round two.
Ten days after the scheduled first-round fixture was postponed because of heavy rain in Essex, Stockton's 24th-minute volley was only parried skywards by Danny Naisbitt with Joe Thompson bundling home as the ball came down.
Stockton found the net himself after the break, turning and beating Matt Paine before driving home, and he then set up substitute Max Power to make it 3-0 in the dying moments.
Despite looking the better side early on, it was Tranmere and not Braintree who fashioned the best chance but Danny Harrison somehow volleyed over a hanging Thompson cross in the 17th minute. However Thompson made no mistake himself seven minutes later, reacting quickest after Iron goalkeeper Naisbitt could only divert Stockton's strike.
Luke Daley - a replacement for James Mulley in midfield - had a great chance to equalise moments later after a long ball from Naisbitt was not fully cleared, but he fired straight at Rovers keeper Owain fon Williams.
A constant threat throughout, Stockton got the goal he deserved seven minutes after the break and then showed his class just before added time sweeping across the box for Power to fire home himself.