Barry Town United reached the quarter finals of the Adran Trophy after a 4-2 win over Flint Town United.
Stevie McCarthy Campbell's side were looking to bounce back after Adran Premier leaders Cardiff City ended their lengthy unbeaten run in all competition last weekend.
Flint, who play in the Adran North, had cruised through the group stages of the trophy with a 100% record, but they were playing only their second game under new boss Oli Williams.
A goalless first half saw Barry dominate the possession and enjoy most of the chances, with Ingrid Aadland and Carys Bufton going closest and away keeper Rebecca Bott making a flurry of crucial saves.
But Barry had to make do for the most part without their captain who was sent off for two yellow cards midway through the first half. It's been a tough fortnight for Lauren Harris, who also scored an own goal in their league defeat at Cardiff City last Sunday.
Flint found the breakthrough on 54 minutes when Jennifer Haynes struck past home keeper Mackenzie Ellingham.
The hosts were struggling to make the most of their chances, but they finally drew level on 65 minutes when sub Ellie Preece's first touch was squared up for Erin Murray to slot past Bott.
The visitors retook the lead just two minutes later via Rosie Hughes, despite huge calls for offside which went unheeded by referee Paul Fisher.
But this cup tie had gone into end-to-end mode when on 70 minutes, Murray volleyed home from a Jasmine Turner corner kick to equalise again.
The quick pace of the second half began to tire on Flint, as Turner turned scorer to edge Barry in front for the first time on 74 minutes, with Preece providing another assist.
And by the 78th minute, the hosts taken full command as Preece broke clear from Murray's cross to bag the fourth goal of a dramatic comeback.
It could have been even more resounding with Turner hitting the post in the closing stages - but Barry had done enough to avoid an upset from an impressive Flint side and book their place in the last eight.
The quarter final draw takes place on Tuesday at 8pm on the FAW's RedWall Plus channel - and among Barry's potential opponents are the only second-tier club left in the competition, Cascade, who knocked out five-time winners Cardiff Met.
Meanwhile, Caldicot Town play host to Barry in the second round of the Bute Energy Welsh Cup on Sunday.