Last season's runners-up, Stoke responded to Danny Kedwell's 16th minute strike with goals from Jon Walters, Cameron Jerome and Robert Huth to ultimately reach the fourth round with ease.
"When it came out of the hat it was a draw you thought was set up for it [an upset]," said Pulis, the Stoke manager.
"I thought we started really slow and couldn't get into the game. When they scored you think 'blimey, let's hope we're not on the end of one'.
"But from that point we gradually took over, we missed some great chances before we actually scored the opening goal.
"After Cammy scored it was a case of making sure we kept nice and steady. We knew we'd have to defend a lot of balls in the box and we did that with Robert Huth and Ryan Shawcross, who were fantastic today."
Pulis was forced to give his post-match assessment in the tunnel, one of the few places in the stadium he was not banned from by the Gillingham chairman Paul Scully.
Pulis managed Gillingham between 1995 and 1999, guiding the club to the brink of the Championship before leaving in acrimonious circumstances, which ended in a court case.
Scally wrote in the match programme that he could never forgive Pulis - but the Gillingham support gave him a standing ovation.
"If he (Scally) wants to say stuff, it's a free world. He can say what he wants. You've seen today who really counts and that's the supporters," Pulis said.
"You've seen what they think of the job I did here. That's all that matters to me. It was very special.
"I had four fantastic seasons here, took a club that was in administration to Wembley, my final game, in front of 90,000 people, we took 38,000 people there.
"It's lovely the supporters remember exactly what happened in that time. I've been back three or four times since and every time they have been fantastic.
"You think as time goes on they will forget but they never have and that [reception] was fantastic.
"The lads have just been giving me some stick, asking which side I was on!"
Gillingham manager Andy Hessenthaler was proud of his side's spirited performance but left to rue the lapses in concentration that were punished by Stoke.
"For the first 35 minutes there was one team in the game and we had a good spell to get another goal but we were punished in the last 10 minutes of the first half," Hessenthaler said.
"That lets them back into the game, we switched off again early in the second half and were punished again.
"But we can come out with a lot of credit for the way we played against a Premiership side. They are a strong side and Tony showed us respect with the team he put out and we gave it a right go.
"As a manager against a Premiership side you worry about being humiliated but we said 'go out there and don't let the game pass you by' and they did that. We played some decent stuff at times.
"We should take lots of confidence from the performance. If we show that commitment and desire we will be where we want to be this season."
Kedwell, Gillingham's leading scorer, had to be replaced during the second half with a suspected fractured rib.
The potential loss of Kedwell would heighten the need for Hessenthaler to bring in reinforcements up front.
Gillingham want to complete the permanent signing of Jo Kuffour, who has been on loan from Bristol Rovers.
Hessenthaler criticised Swindon for announcing on the eve of the FA Cup weekend they had made a bid for Luke Rooney.
"To go on the radio and say they have made a six-figure bid is not good conduct. Rooney is a good player. We want him to stay at the football club," Hessenthaler said.
"We have offered him a deal but we haven't reached an agreement."