“I've practised a lot over the last few days and this is the result”
Swail's victory takes him through to the last 16 in Galway and a clash with fellow NI player Mark Allen.
"If you look at my track record you know that I don't give in," said Swail.
Scotland's Maguire looked to be cruising as breaks of 89, 56 and 52 put him 3-0 up.
But Swail nicked the fourth by clearing from yellow to pink, and when Maguire missed a black off the last red in the fifth frame with victory within his grasp, the momentum was with Swail.
The Ulsterman clinched that frame on the colours then a run of 69 got him back to 3-3. Swail missed a red on 23 in the decider, only for Maguire to fail on a red to the same centre pocket.
A further 42 from Swail left his opponent needing snookers and when he potted the last red he was through to the last 16 to face Allen, who beat Mark Davis 4-0 later in the evening.
"I haven't had much to shout about over the last few years, it has been tough," added the 43-year-old.
"I knew things would turn around on and off the table. I knew sooner or later it would come, but what a way for it to come here, beating one of the top players from 3-0 down. I'm absolutely over the moon.
"No matter how bad things are I always stick at it. I've practised a lot over the last few days and this is the result."
survived a tough test against Jamie Burnett, coming from 2-0 down to win 4-2 and set up a match with
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.