Andy Murray hopes his latest injury will not rule him out of his Wimbledon swansong next month after withdrawing from the Queen's Club Championships on Wednesday.

The former world number one was forced to retire against Jordan Thompson five games into their second-round encounter due to a back injury and pain in his right leg.

It was a sad end for Murray, who has won the tournament a record five times. However, attention will immediately turn to being fit for Wimbledon, which starts on July 1.

"Let's hope it will be OK with some rest and treatment, and I'll still be able to play [at Wimbledon]," said Murray, who won two Wimbledon titles in 2013 and 2016.

The three-time grand slam champion was set to play an exhibition event in Hurlingham next week before Wimbledon but looks likely to miss the event.

Murray had said earlier this week he felt ending his illustrious career at Wimbledon or the Olympics would be a fitting stage to retire from the sport.

The Scot is set to undergo a scan on Thursday to clarify his potential participation at the tournament next month, where he is also due to play in the doubles alongside his older brother, Jamie.

"I don't know exactly what the problem is. I hadn't experienced that before," said Murray. "I have no idea how long it will take to get better and what the treatment options are."