Andy Murray announces he plans to retire from tennis this year due to his right hip injury, admitting he's been "struggling for a long time." (2:27)

MELBOURNE, Australia -- Andy Murray said Friday he plans to retire after Wimbledon because of his right hip injury -- if he can keep playing beyond this month's Australian Open.

In an emotional news conference at Melbourne Park, the 31-year-old former world No. 1 said the pain had become too much to bear and that he had made the decision last month during his training camp.

"I spoke to my team and I told them I can't keep doing this and that I need to have an end point, because I was just playing with no idea when the pain was going to stop," said a tearful Murray. "I said, look, I think I can kind of get through this until Wimbledon. That is where I would like to stop. I'm also not certain I'm able to do that.

"I can still play to a level, not a level that I'm happy playing at. But it's not just that. The pain is too much, really. It's not something I want. I don't want to continue playing that way. I've tried pretty much everything that I could to get it right, and that hasn't worked."

Murray, who won three Grand Slam titles -- Wimbledon in 2013 and 2016 and the US Open in 2012 -- and two Olympic gold medals, had hip surgery in January 2018.

He returned to the tour last summer but was clearly struggling with his movement. However, it was the pain -- and the desire for a better quality of life -- that made up his mind.

Murray said he will play the Australian Open, where he has been drawn against No. 22 seed Roberto Bautista Agut on Monday, but he admitted this could be his final tournament.

"There's a chance for sure," he said, "because I'm not sure I'm able to play through the pain for another four or five months. I have an option to have another operation, which is a little more severe than I had before, having my hip resurfaced, which will allow me to have a better quality of life and be out of pain. That's something I'm seriously considering.

"Some athletes have had that and gone back to competing, but there's obviously no guarantee and it is certainly not something, the reason for having an operation like that is not to return to competitive sport, it's for a better quality of life."

Andy Murray briefly left his news conference to compose himself. Scott Barbour/Getty Images

Murray said he would not consider playing as a doubles specialist but that he hoped he would be pain-free in the future.

"You guys see me running around a tennis court, walking between points, I know it doesn't look good and it doesn't look comfortable," he said. "There are little things, day to day, that are also a struggle. It would be nice to be able to do them without any pain, putting shoes on, socks on, things like that.

"That's the main reason for doing it. If I was to have an operation for that, I would rehab correctly, do it properly to give my hip the best chance as being good as it can be. But I am also realistic knowing that's not an easy thing to come back to or play professional sport to a high level."

Murray said he had played with hip pain for much of his career but that the real problems began in the 2017 French Open semifinal, when he was beaten in five sets by Stan Wawrinka.

"I have a severely damaged right hip. Having the operation last year was to give it the best possible chance of being better," Murray said. "I have been playing with hip pain for a number of years. It wasn't as if it had just started at the French Open after my match against Stan.

"It got to a level where I didn't recover from that match, pushed it over the edge, having the operation would hopefully make it as good as possible. It didn't help with the pain at all. That is the thing I have been struggling with.

"The walking, there are certain things on the court I cannot really do properly now, but the pain is the driving factor. I can play with limitations, that's not an issue, it's having the limitations and also the pain is not allowing me to enjoy competing, training or any of the stuff I love about tennis."

Murray, who will turn 32 before this summer's Wimbledon, became the first singles player from the United Kingdom officially to be world No. 1 when he topped the rankings Nov. 7, 2016. The Scot was given a knighthood the following month.