World number 43 Matthew Stevens held his nerve against Mark Selby to earn a dramatic 6-5 victory over the three-time UK Championship winner in the last 16 at the York Barbican.
Welshman Stevens, the 2003 champion, led the world number six 3-1.
Selby took the next three but Stevens managed to level at 4-4 and 5-5 and won a tense 46-minute decider in the early hours of Friday morning.
Stevens now faces 2004 champion Stephen Maguire, who beat Michael White 6-4.
White’s fellow Welshman Stevens has not been beyond the second round of a ranking event this season and last reached the quarter-finals of the event in 2012.
But he outplayed Selby for much of the match and showed great composure to win two tense, tactical frames to close out victory.
Gutsy Maguire battles past White
World number 14 Maguire was making his 16th consecutive appearance in the last 16 and aiming for a ninth quarter-final in the past 12 years, but was outplayed early on.
Two-time ranking event winner White, a former world number 15, has dropped to 62 in the rankings.
But the 28-year-old seemed buoyed by his thrilling final-frame win over Mark Davis in the last round, as two centuries and breaks of 66 and 91 saw him lead the Scot 4-2.
Maguire, 38, won a tense seventh frame and a break of 56 levelled the scores.
A disastrous first shot by White on a re-spotted black gifted frame nine to Maguire, who rounded off the win with a stylish 116 clearance – his highest break of the match.
“Winning the frame on the re-spotted black was huge. When he was 4-2 up he should have killed me off,” Maguire said.
“But it was a nice century to wrap it up and I am through so that’s the main thing. I can’t improve if I am driving up the motorway.”