Swaffham's FA Vase dream is over after they were beaten in a third round replay.
The Pedlars went ahead through Joe Jackson's 21st-minute opener, but Stowmarket gained the ascendancy during the final hour.
Scott Chaplin swept home a 34th-minute equaliser, before centre-half Sam Nunn climbed high to head home a free-kick, with 20 minutes left, to seal victory.
Stowmarket's reward is a fourth round tie away at either Tring Athletic or Biggleswade.
Stowmarket could count themselves a little lucky to be on level terms at the break, because the Pedlars forced the pace for much of the first half.
Home keeper, Callum Robinson, was called into action on four minutes when diving to his right to divert Alex Vincent's 20-yarder around his post.
Stow had to weather the storm, but finally threatened for the first time in the 16th minute, from a corner routine, with ex-Braintree Town stalwart Matt Paine flashing a header wide of the far upright.
However, it was Swaffham who drew first blood, via the direct route with keeper Tommy Rix punting the ball upfield. Stow's defence failed to clear the initial shot by Jackson, and were made to paid as Jackson buried the rebound with a smart low drive.
A mazy run by livewire Vincent handed Jackson the chance to double the lead on the half-hour mark, but this time his goalbound drive was well saved by Robinson.
Four minutes later and the Suffolk side were level. The Pedlars failed to clear a free-kick and Jack Baker helped the ball into the danger zone, where Chaplin tucked it home from six yards out.
The hosts had the ball in the back of the net, when Baker slammed home Tom Walters' cross from close-in on 50 minutes, but the goal was ruled out for offside. However, there was no reprieve for the visitors when Nunn climbed high to head home a 70th minute free-kick, with what proved to be the winner.
Baker was sent off in injury-time, but it was too late for Swaffham to capitalise.
Comments: Our rules
We want our comments to be a lively and valuable part of our community - a place where readers can debate and engage with the most important local issues. The ability to comment on our stories is a privilege, not a right, however, and that privilege may be withdrawn if it is abused or misused.
Please report any comments that break our rules.
Read the rules here