Luke Shaw admitted the prospect of signing a new five-year deal at Manchester United may have seemed “impossible” until recently following a chequered spell with the club.

The left-back’s contract was due to expire next summer and it seemed he was on the brink of exiting Old Trafford only a few months ago after yet more public criticism from manager Jose Mourinho.

Shaw, though, has been a regular under the Portuguese this season and has decided to commit his long-term future to the club he joined from Southampton for a fee thought to be £30million in June 2014.

He said on the club’s official app: “I’m very proud and happy. It’s been an odd four years for me.

“There have been ups and downs. From signing today now it’s all about looking forward and to how much I can help the team and become a success again.

“If you look at my situation in the last year and a bit, you’d have thought this could have been impossible. But I worked hard, I wanted to be here and I wanted to make sure my future was here to help this club.”

Injuries, form and fitness issues as well as a tumultuous relationship with Mourinho have punctuated Shaw’s time in the north-west.

He has made just 75 appearances in total, 50 of them in the Premier League, during his near four-and-a-half-year stay after moving to United, shortly after making his England debut aged 18.

The transfer made Shaw the most expensive teenager in world football at the time but his career took a monumental hit in September 2015 when he suffered a double leg-break in a Champions League game against PSV Eindhoven.

Shaw revealed last month he nearly lost the leg, while it would be nearly a year before he made another competitive appearance.

Mourinho has condemned Shaw’s attitude and focus in the past while he questioned the tactical awareness of the defender following an FA Cup win over Brighton in March.

The public flak led to reports of Shaw thinking about leaving the club, but his improved form this season saw him earn an England recall last month after missing out on Gareth Southgate’s World Cup squad.

“I think I knew how important this season was going to be, especially the start of it coming in the last year of (my contract),” he said.

“I’m really happy to be in this form and over the pre-season I was working very hard to make sure that I gave myself the best opportunity to be able to put myself in the team, and thankfully I have done that.

View this post on Instagram

What a feeling! ❤ #MUFC

A post shared by Luke Shaw (@lukeshaw23) on

“The hard work isn’t over. I want to stay in the team now and keep the shirt so I’ll keep going, keep focused and keep concentrating. That’s what I’m going to be doing.”

Shaw’s form has been one of the few positives for United this season, with Mourinho under heavy scrutiny following a difficult start to the campaign that has seen the club lose three of their opening eight top-flight fixtures.

The 23-year-old is convinced better times lie ahead, adding: “I think personally it’s only a matter of time that the success is going to be coming back.

“I can see the team that we have here. We have an amazing group of players and the talent we have is scary, there are a lot of young lads that are hungry for trophies.”

Mourinho had warm words of encouragement for Shaw, saying: “Luke fully deserves this contract. He understood his development process, he has worked really hard at every level and he always believes in himself which is a great attribute to have.

“Luke is still young and is improving all the time and he must feel very proud of himself. I am delighted that we are keeping such a talented young English player with a bright future ahead of him.”