International career
In February 2001, Torres won the Algarve Tournament with the Spain national under-16 team. The under-16s took part in the 2001 UEFA European Under-16 Football Championship in May, which they also won, with Torres scoring the only goal in the Final, as well as finishing as the tournament's leading scorer, and was also named the player of the tournament. In September 2001, Torres represented the under-17 team at the 2001 FIFA Under-17 World Championship, but the team failed to progress through the group stage.In July 2002, he won the 2002 UEFA European Under-19 Football Championship with the under-19 team and was again the only goalscorer in the Final. Also, he finished as top scorer and was named player of the tournament. "We complement each other very well. We get on well on the pitch and very well off it too. We're a good partnership. We both chase down defenders, put pressure on and fight to create chances for each other."
He scored seven goals in 11 appearances in qualifying for the 2006 FIFA World Cup, making him Spain's top scorer for qualification, including a vital two goals against Belgium and his first international hat-trick against San Marino. At his first ever appearance in a FIFA World Cup finals at the 2006 FIFA World Cup in Germany, Torres scored the final goal in a 4–0 victory over Ukraine with a volley. In the second group match, Torres scored twice against Tunisia, first in the 76th minute to take Spain 2–1 into the lead, and then again from a penalty kick in the 90th. With three goals, he finished the tournament as Spain's top scorer along with fellow striker David Villa.
He was called up for Spain's UEFA Euro 2008 squad, where he set up Villa to score Spain's first goal of the tournament in the first game in the group stage against Russia. Torres came under criticism for apparently refusing to shake the hand of Spanish manager, Luis Aragonés, after being substituted. He subsequently denied being angry with the coaching, saying that he was actually "irritated with himself". He scored his first goal of the tournament in Spain's next game, a 2–1 win over Sweden. Torres scored the winner and was named the man of the match in the Final against Germany in a 1–0 victory. He said "It's just a dream come true. This is my first title and I hope it's the first of many. Victory in a Euro, it is almost as big as a World Cup. We are used to watching finals on television, but today we were here and we won. My job is to score goals. I want to win more titles and be the most important player in Europe and the world."He was later named as a striker along with his striking partner Villa in the Team of the Tournament.
Torres made his 60th appearance for Spain in a 2010 FIFA World Cup qualification victory over Turkey on 28 March 2009, becoming the youngest player to reach this milestone. He was named in Spain's team for the 2009 FIFA Confederations Cup in June. He scored his second hat-trick for Spain after 17 minutes into a Confederations Cup game against New Zealand on 14 June, thus recording the fastest hat-trick by a player for Spain. He played for Spain as they were defeated 2–0 by the United States in the semi-final, as well as the third-place play-off, which Spain won 3–2 against South Africa after extra time.
Having undergone knee surgery on 18 April 2010, and missed the end of the Premier League season, Torres' rehabilitation and fitness was closely monitored by Spain manager Vicente del Bosque. Although still out injured, Torres was selected for Spain's 2010 FIFA World Cup squad in May.On 8 June, Torres made his first appearance on the field in exactly two months, coming on as a substitute on 66 minutes against Poland in a pre-World Cup friendly. He came on as a substitute on 61 minutes in Spain's opening World Cup game on 16 June, a 1–0 defeat to Switzerland. He started the next two games against Honduras and Chile and although his performances in the group stage were described as below-par, he received backing from manager Vicente del Bosque. Torres came on as a substitute on 105 minutes in the Final as Spain won the FIFA World Cup for the first time following a 1–0 victory over the Netherlands on 11 July 2010.