BBC Sport takes a look back at Sir Alex Ferguson's football career in pictures
Sir Alex Ferguson announced on Wednesday that he's stepping down as manager of Manchester United. It comes just two weeks after he celebrated winning his 13th league title with the Red Devils after a 3-0 victory against Aston Villa at Old Trafford.
In true United fashion under Ferguson, it was a late comeback and stoppage-time winner from Ole Gunnar Solskjaer that secured his first European Cup in 1999. Teddy Sheringham had scored the first before Solskjaer got the winner. Both were substitutes.
Born in Govan on 31 December 1941, Alex Ferguson played for 17 years as a striker - for clubs Queen's Park, St Johnstone, Dunfermline Athletic, Rangers, Falkirk and Ayr United.
In 1985 Sir Alex became Scotland's caretaker manager after Jock Stein's sudden death - he led the national team at the 1986 World Cup in Mexico. But he said he didn't want to take the job permanently.
Ferguson managed both East Stirling and St Mirren, but it was at Aberdeen when he emerged as one of the leading coaches in Europe. He broke Rangers and Celtic's dominance in Scottish football. Between 1978 and 1986, he won three league titles with Aberdeen, four Scottish FA Cups, one Scottish League Cup win and lifted the European Cup Winners' Cup and European Super Cup in 1983.
Despite dominating in England during the '90s, Ferguson said he always wanted to win the Champions League. His big moment came in 1999 when the Reds scored twice in injury-time to come from behind to beat Bayern Munich in the final in Barcelona. It completed a historic "treble" that season which also included the Premier League and FA Cup.
After overcoming that difficult start to his career at Old Trafford, Ferguson won his first trophy at the club in 1990 when he led them to an FA Cup final replay win over Crystal Palace at Wembley - Lee Martin scoring the only goal after the first match had ended 3-3.
To complete a remarkable year for Ferguson, he was awarded a knighthood in the Queen's Birthday Honours in June 1999, picking up the honour alongside his wife Cathy.
United's title success of 2011 was particularly meaningful for United, because it went past arch-rivals Liverpool's record of 18 English league victories.
Following that historic 19th title, United named a stand at Old Trafford after Sir Alex Ferguson - their most successful ever manager.
Neighbours Manchester City, under new rich owners, pipped United to the title in 2011-12 but Ferguson soon restored United's superiority and wrapped up his side's 20th title in 2012-13, beating Aston Villa to win the league with four games to spare.
Alex Ferguson replaced Ron Atkinson as Manchester United manager in November 1986, with the club second from bottom in the Division One (the top division) table. He led them to 11th by the end of the season.
But his fierce determination to win has sometimes spilt over into clashes with referees. The United manager has been punished by the Football Association on numerous occasions.
Sir Alex's famous time-keeping led to the phrase 'Fergie-time' being coined - a term to describe the amount of time added on at the end of a match. A study in 2012 showed that United played longer than any other team when losing...
Steve Bruce scores a stoppage-time winner as Manchester United come from behind against Sheffield Wednesday on 10 April to earn a vital three points in the race for the 1992-93 title. United were crowned champions when Aston Villa lost 1-0 to Oldham on 2 May - it was their first championship win since 1967.
Sir Alex Ferguson was famously told that United had ended their 26-year wait for an English league title by a stranger while he was out playing golf, as he refused to watch Aston Villa's game with Oldham. United's players had watched the events unfold at Steve Bruce's house. It was the first of 13 league titles United won under Ferguson.
Mark Hughes celebrates winning the European Cup Winners' Cup having scored United's two goals in the 2-1 win over Barcelona. It was the second time Ferguson had won the trophy having already won it with Aberdeen in 1983 - but this was Sir Alex's first European trophy as United's manager.
Sir Alex struggled in his early years at Old Trafford and after his first two full seasons had ended without any trophies, the pressure was on. After an eight-game spell in the league without a win, reports suggested that if United lost to Nottingham Forest in their FA Cup third-round tie on 7 January, 1990, Ferguson would be sacked - but Mark Robins scored the winner that went down as the "goal that saved Fergie".
In total, Ferguson won the FA Cup five times - including against arch-rivals Liverpool in 1996 when Eric Cantona (centre) scored the winner in the 85th minute to complete a league and cup double.
Edwin van der Sar saved the penalty that secured Ferguson's second European Cup. Ferguson had struggled to find a replacement for Peter Schmeichel, who left the club after their 1999 European success, until he signed Van der Sar in 2005 from Fulham.
Another of Ferguson's big signings was Cristiano Ronaldo. The United boss signed the Portuguese star in 2003 for £12.24m. Ronaldo won three league titles, a European Cup, an FA Cup and two League Cups before leaving for Real Madrid in the summer of 2009 in a record £80m deal.
Ferguson reckons that it was when he signed the French firebrand, Eric Cantona for £1.2m midway through the 1992-93 season he paved the way for big-time success at Old Trafford. Cantona had led Leeds to the title the previous season.
After winning the Champions League once, it became an obsession of Sir Alex to win the trophy again - and he succeeded in 2008 when United beat Chelsea on penalties in the final in Moscow.