Port Vale 1 Wrexham 1. Wrexham win on pens
Vale's Danny Whitaker struck the post with the only failure from the spot and the loss was an early body blow for Vale's fragile finances.
It was all Vale in the opening stages when Luke Rodgers had one effort saved by Michael Jones, struck another against a post and a third narrowly off target.
But Wrexham took the lead in their first attack when Michael Proctor took advantage of some sloppy defending in the 11th minute.
Danny Williams pumped forward a long ball more in hope than expectation, but Vale keeper Joe Anyon stood rooted to his line and Proctor evaded Keith Lowe's challenge to squeeze in his shot from a tight angle.
Vale came roaring back with Lowe's header cleared off the line by Simon Spender before Shane Tudor struck the bar and shot another chance wide with the goal gaping.
But Vale's pressure was incessant and they were finally rewarded with a 34th minute penalty.
Richard Hope was guilty of a clumsy challenge on Calum Willock and Rodgers stepped up to belt home his second penalty in four days.
Vale's supremacy continued, with Llewellyn's header into the hands of Anyon a brief interlude, and the home side should have taken the lead on the stroke of half-time.
Willock's clever pass sent Craig Rocastle racing clear but the midfielder scooped his shot straight at the advancing Michael Jones.
Wrexham were forced to survive again at the start of the second-half with Tudor firing into the side netting and the dangerous Rodgers having a shot well-saved by Jones.
But the visitors rode the storm and almost regained the advantage when Llewellyn's header from substitute Josh Johnson 's cross drew a fine save from Anyon.
Wrexham, rejuvinated by the young legs of substitutes Johnson, Marc Williams and Conall Murtagh were the better side after that and twice came close to winning in extra time.