Leeds chairman Ken Bates said: "We believe the appointment is arguably the most important we have made.
Joy as QPR are promoted in 2010-11
"The objective was to appoint a manager who had a proven track record of getting teams promoted and in Neil we have a man whose record is second to none.
"We want to be in the Premier League and we will support Neil in the quest to get us there."
Youth team boss Neil Redfearn, who has been in temporary control of first-team affairs at Elland Road, will take charge for Saturday's game against Doncaster Rovers before returning to his role in the academy.
Warnock, one of only 19 bosses to have taken charge of 1,000 domestic matches in England, spent 20 months at Loftus Road and led Rangers to promotion from the Championship last season.
He began his managerial career at Gainsborough Trinity before leading Scarborough to the Football League and winning successive promotions with Notts County.
Promotions with Huddersfield and Plymouth were followed by spells in charge of Oldham and Bury, with Warnock taking control at hometown club Sheffield United in December 1999.
He led the Blades to semi-finals in both the FA and League Cups and, after a play-off final defeat, promotion to the Premier League in 2006.
Warnock then took charge of Crystal Palace before moving to QPR.
Grayson, who was sacked after three years in charge at Elland Road, guided Leeds to promotion from League One.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.