The Glassboys earned a clash with Lancaster City in the second qualifying round after seeing off visiting Nuneaton.
Ashley Carter scored direct from a free-kick just outside the box to put the hosts in front.
That strike was cancelled out by a goal from former Glassboy Luke Benbow.
But the home side were not to be denied and clinched the win with a thumping strike from Josh Ezewele.
Hednesford came from behind to beat Stratford.
The hosts threatened first when Matthew Campbell forced Andrew Wycherley into a save.
The Pitmen responded with Danny Glover’s header saved by home keeper Jack Bennett.
But it was Stratford who struck first on 16 minutes thanks to a fine lob from Ravin Shamsi.
Hednesford were back on level terms seven minutes later when Reece King headed home from a corner. 1-1.
And the winner came just before the hour mark, Tom Elliott netting after a mix up in the Stratford defence.
The Pitmen will travel to Sutton Coldfield in the next round.
Halesowen face a replay at Stamford next week after drawing 2-2 at The Grove.
Montel Gibson bagged a late equaliser for the Yeltz who had earlier led through Robbie Bunn.
But there was no joy for Chasetown as they lost 2-0 at Leek.