Five-time Grand Slam champion Swiatek was pushed hard by the former Australian Open winner but prevailed 6-3 6-4
Novak Djokovic on Thursday backed Andy Murray to keep playing despite the insistence of his career-long rival that he is bidding farewell to tennis this year.
Djokovic and Murray have been rivals since they were 12 years old and have clashed 36 times as professionals. That includes seven Grand Slam finals.
"I do wish him all the best in his farewell," said Djokovic.
"But I wouldn't be surprised if he decides to come back again. He's an incredible competitor -- resilience that you can definitely study and teach young athletes."
Murray pulled out of Wimbledon singles after failing to recover from a back operation but is playing men's doubles with brother Jamie on Thursday and mixed with Emma Raducanu later in the tournament.
The former world number one and three-time major winner said he will retire after the Paris Olympics.
"If this is his last match, obviously it's sad that he's not able to finish in his own terms in singles," said Djokovic.
"Playing alongside his brother is probably even more emotional for everyone -- for them, for the family."
Earlier Thursday, Djokovic was made to fight by British outsider Jacob Fearnley before reaching the Wimbledon third round for the 18th time.
Seven-time champion Djokovic triumphed 6-3, 6-4, 5-7, 7-5 but had to save two break points midway through the fourth set before seeing off the challenge of the world number 277.
"I had never seen him play so there is always the element of surprise," admitted Djokovic.
"He had nothing to lose and served well. I was a little lucky in the fourth set. I could have won the match in three and it could have gone to a fifth.
"The way he was playing, I'm glad it didn't."
The 37-year-old Djokovic had cruised through the first two sets on Centre Court against a player who was making his Grand Slam debut this week.
World number two Djokovic will take on Australia's Alexei Popyrin for a place in the last 16.
ALSO READ:
Five-time Grand Slam champion Swiatek was pushed hard by the former Australian Open winner but prevailed 6-3 6-4
Golf Federations from around the world were invited by The R&A to select their best boy and girl golfer under the age of 16 to participate in the event
The Indian-born Dubai resident hopes to build on her recent success in the European Championship in Scotland
German legend Bernhard Langer plays his final tournament on Tour at the BMW International Open in Munich
Spokesman defended the actions of medical staff and local organisers after footage showed what appeared to be a hesitant response to the teenager's fall
Ronaldo, who missed a penalty in extra time, broke down in tears following the game as he was unable to finish an interview
Girmay timed his effort to perfection to beat Colombian Fernando Gaviria and Belgian Arnaud de Lie
The 'extremely dangerous' storm is expected to bring life-threatening winds and flash flooding in the Caribbean's Windward Islands