The magic of the FA Cup is alive and well in this corner of south Wales. Newport County, 74 places below Leicester City on the league ladder, served up a giantkilling that will be talked about for years to come in these parts as Jamille Matt and Pádraig Amond scored the goals that inflicted a humiliating defeat on Claude Puel’s side.

There were wild scenes at the final whistle as Newport celebrated their first victory over top-flight opposition in the FA Cup since 1964. Michael Flynn, the Newport manager, was walking around the pitch with his son on his shoulders come the end and there was a mixture of jubilation and disbelief among the home supporters as they departed with a spring in their step.

Rachid Ghezzal had threatened to spoil the party when he equalised with eight minutes remaining – the same point Harry Kane scored here last season to earn Tottenham Hotspur a 1-1 draw in the fourth round – but Newport were determined that history would not repeat itself on this occasion.

Marc Albrighton gave the League Two club a helping hand in more ways than one. The Leicester winger raised his arm, presumably to protect himself, when Vashon Neufville crossed from the left and the referee, Chris Kavanagh, immediately pointed to the spot. Amond, Newport’s leading scorer, was the calmest man in the stadium as he coolly dispatched his penalty past Danny Ward.

Newport County v Leicester: FA Cup third round – live! Read more

What a chastening experience for Leicester and in particular Puel, who seems to be forever taking one step forward and two back. His decision to field an understrength team in the Carabao Cup against Manchester City last month went down badly and the Frenchman left himself open to further criticism by making seven changes here. Jamie Vardy was nowhere to be seen and seasoned watchers will not be surprised to learn that Leicester looked toothless up front without him.

At the same time Puel was entitled to believe there was more than enough talent on the pitch to overcome a side currently sitting 13th in League Two. “I think we had a good team, with eight who had won the title with Leicester and a lot of experienced players and quality on the pitch,” Leicester’s manager said. “I don’t want to look for excuses about this.

“We had a lot of respect for this [Newport] team. We knew it was a difficult game with difficult conditions – we knew this context. And it was important to have experienced players to manage this game and to find a solution. We tried, but it was not enough. I don’t know if we deserved it or not. They made a fantastic upset, it will be a fantastic memory for them.”

Flynn, not surprisingly, was beaming. “It hasn’t really sunk in yet. I feel extremely proud, it’s huge for me, the football club, the community, all the fans and the players. We’ve beaten a very good Premier League team. We couldn’t beat Stevenage who had 10 men on New Year’s Day. It’s crazy how the players can raise their levels and keep concentrating for 95 minutes against a team that is seventh in the Premier League.”

This was classic third-round territory in so many ways. Rodney Parade was packed to the rafters, there were rugby markings on a pitch that looked a little bare in places, and the atmosphere crackled under the lights as the home supporters greeted every header, block and tackle with huge cheers. Throw a weakened Leicester team into the mix and an early Newport goal, and all the ingredients were there for an upset.

Matt’s opener was a terrific goal. Robbie Willmott was the architect with a lovely piece of wing play as he skipped past Christian Fuchs before delivering a deep cross that Matt met with a towering header after losing Wes Morgan. Shinji Okazaki squandered a golden chance to level when he headed wide from inside the six-yard box and Albrighton saw a goalbound shot deflected over the bar after some brilliant last-ditch defending, but Leicester generally looked ragged and flat in the opening 45 minutes. Indeed, Matt, stretching to reach Amond’s cross, came close to doubling Newport’s lead.

The pattern of the game changed in the second half as Puel introduced James Maddison and Leicester pinned Newport back. Albrighton clipped the top of the crossbar, Kelechi Iheanacho, who was hugely disappointing, saw his header saved and later thrashed a volley wide. Newport’s brave resistance was finally broken when Ghezzal thumped a wonderful 20-yard shot into the top corner.

The real drama was still to come, however, as Amond stroked home from the spot to send Newport into the fourth round. “I want Liverpool home or away,” Flynn added.