A basketball-style first half saw the Reds go ahead via a Shkodran Mustafi own goal, only for Lucas Torreira to level before Gabriel Martinelli bagged twice to put the Gunners clear.
James Milner ensured the tie was still alive with a penalty ahead of the interval – but then, nine minutes into the second period, had a short back-pass punished by Ainsley Maitland-Niles.
Emphatic strikes at the Kop end from Alex Oxlade-Chamberlain and Divock Origi in the space of four minutes got Jürgen Klopp’s side on terms again.
Joe Willock looked to have had the last word with a swerving thump from distance, until Origi volleyed in a fifth for the Reds in stoppage-time and forced a shootout.
And the hosts were victorious from 12 yards as Caoimhin Kelleher saved brilliantly from Dani Ceballos and Curtis Jones kept his nerve to seal it.
Curtis Jones talking to BBC Radio 5 Live: “Being a local lad it’s always been my dream to get an appearance at Anfield. To get an assist to give us a chance and then to score a penalty is just a dream come true.
“I was calm, I picked my spot and I was fortunate enough that the winning penalty went in. The team played great, they showed character and belief. The fans were unbelievable too, they helped us through the game and we’re glad we paid them back.
“We knew regardless of the Arsenal team it was going to be a tough game. We knew we could match them and that’s what we did tonight.
“This is just the beginning, I’m just a young lad and I’ve still got a long way to go. Any opportunities I’ll take with both hands.”
Divock Origi talking to BBC Radio 5 Live: “It was unbelievable. It was another special night at Anfield. We enjoyed it a lot.
“There were a lot of goals, it must have been very exciting to watch from the outside. I think even I’ll watch it again.
“I’m happy I was grateful I could help the team. We just wanted to show again that we have an unbelievable team.
“They are a very good team, they have good prospects. We knew it was going to be a difficult night. We showed mentality and we know anything can happen in football.”
Jamie Carragher said Liverpool’s shoot-out win would be the best night of some of their young players’ lives, and how they deserved those memories after going toe-to-toe with a far more experienced Arsenal side and ultimately coming out on top.
The one minor disappointment was that of Rhian Brewster, tipped for a breakthrough season at Anfield this year but who did little to suggest he can make an impact at the top-end of the Premier League.
“I thought the young players on both sides were, in some ways, better than the senior ones,” Carragher added.
“We made some mistakes, we played some average passes. We were too open at times. We can talk about tactics but who cares on a night like this? I hoped for the boys they would have a game to remember. What they did tonight, I lost it really.
“It’s like a dream to play for the first time at Anfield, but things might not be going right and you have to stay on track. All our goals we cored were wonderful.
“Kelleher is an outstanding talent. The crossing from Williams, he might not thought he would play tonight.
“Jones… it was not my decision in the end for him to take the last penalty. When I saw the list Origi was the taker of the last one and they changed it obviously.
“If you don’t win nobody remembers it in three years, if it works out the boys will remember it forever.” Liverpool boss Jurgen Klopp told Sky Sports.
Arsenal manager Unai Emery: “A crazy match. I am very proud of their work, we had a high rhythm in the first 45 minutes. At the end we were winning until the last action. Penalties are 50/50 and we lost.
“We are sad but our work, we deserve to have more. There are lots of positives to take.
“Defensively, both teams cannot be happy with that. But for the supporters it was an amazing 90 minutes. The result was always changing. It was spectacular.
“We can be proud of our work but not the result. Mesut Ozil is back helping us with his quality and his spirit. He played with good spirit, quality.
“It was in the plan to replace him, we had spoken about that before.
“Granit Xhaka? Now I cannot say how we are going to play on Saturday. We have to take it step by step.”