Carrick announced his decision after leading United to a 3-2 win over Arsenal in the Premier League on Thursday.
The 40-year-old had been acting as caretaker manager ever since Ole Gunnar Solskjaer was sacked, having served under both the Norwegian and Jose Mourinho as a first team coach.
Carrick stayed unbeaten in his three games as a caretaker, recording two wins and one draw, but will now make way for Ralph Rangnick, who has been appointed until the end of the season.
Carrick initially joined Manchester United as a player from Tottenham Hotspurs in the summer of 2006 and went on to make 464 appearances for the club, winning among others five Premier League titles and the UEFA Champions League in 2008.
Carrick said: "My time at this great club will always rank as the best years of my career. When I first signed over 15 years ago, I never in my wildest dreams could have imagined winning so many trophies and I will certainly never forget the fantastic memories both as a player and as a member of the coaching team.
"However, after a lot of thought and deliberation, I have decided that now is the right time for me to leave the club. I want to place on record my thanks to all of the players and a special mention goes to the backroom staff, working long hours with such a great group of people has been a real pleasure and I have made some long-lasting friendships.
"I am, and will always be, a Manchester United fan and will come to as many matches as possible. I would like to wish Ralf, the staff, the players and the fans all the best for the future and I look forward to being in the stands and supporting the boys as a fan."