Milivoje Novakovic gave Slovenia the lead against the run of play in the 37th minute at the Stozice Stadium, before Jack Wilshere broke his international duck with a pair of brilliant, almost identical second-half goals to put England ahead.

Slovenia substitute Nejc Pecnik appeared to have rescued a point with an 84th-minute equaliser, but moments later Rooney atoned for two glaring earlier misses by scoring his 48th England goal, taking him level with Gary Lineker and leaving him one goal behind Bobby Charlton.

"It's great to score the winner, but it was a great team performance," Rooney said. "We came out on the front foot for the second half and Jack Wilshere scored two great goals."

Rooney's strike gave England a sixth win in six qualifying games, keeping them six points clear at the Group Esummit from Switzerland, who came from behind to win 2-1 in Lithuania.

England finished a season unbeaten for the first time in 24 years, and the display also allowed Roy Hodgson's men to answer some of their critics after they were lambasted for an anaemic goalless draw against the Republic of Ireland in their previous outing.

"It's a good achievement. Having a complete season (unbeaten), with eight wins and two draws, has not been done for well over 20 years," Hodgson said. "I think the players deserve a great deal of credit for that. Now we just need to keep building on it."

Hodgson made three changes to the team that had started in Dublin, with Kieran Gibbs, Fabian Delph and Andros Townsend coming in, but it was a player whose place was thought to have been under threat, Raheem Sterling, who provided the hosts' spark.

Twice Rooney freed Sterling to run at goal in the early stages, but after side-footing his first attempt over the bar, he then saw a low shot deflected behind.