Unemployed Jamie Michael Mason was behind the wheel of a Ford Focus that he said be bought from eBay for £250, and went driving with three of his friends despite having no licence or insurance.
Prosecuting at Leeds Crown Court, Satpal Roth-Sharma said police tried to pull the Focus over on White Apron Street, South Kirkby, at around 1.15pm on April 27.
The car accelerated away and reached speeds of up to 55mph as it led the police on a chase along Mill Lane, Stockingate and Mill Close, a cul-de-sac in which he mounted the pavements and drove along a grass area to West Street, then back along Mill Lane, Holmsley Lane and Common Road towards Brierley.
Carrying on to Grimethorpe, he then went through a set of red lights and into the path of a bus which had to take evasive action to avoid a collision.
The police chased the Focus to Chestnut Street in Grimethorpe, where Mason and his passengers abandoned the car in a wooded area and fled.
The police quickly apprehended Mason. They used a drug wipe test and found he was over the limit for cannabis and cocaine.
The 44-year-old, of St James' Court, Havercroft, admitted dangerous driving, driving without a licence and insurance and being over the drug-drive limit for cocaine and cannabis.
He has 11 convictions for 28 offences, but had not been before the courts for more than 19 years.
Mitigating, Nathan Davis, said that Mason had made full admissions from the outset. It was heard that Mason was a regular cannabis user, but had taken cocaine as a "one off".
Judge Tom Bayliss QC jailed him for eight months and two weeks and said: "It was a prolonged period of dangerous driving at high speed under the influence of drugs.
"It's a shocking case of dangerous driving and there has to be a prison sentence for this type of offending.
"Anyone who drives in this manner must expect to go to prison."
He also banned Mason from driving for two years, four months and one week, and told him he must sit an extended retest to get his licence.