A driver caused chaos on the M62 as he swerved across three lanes of the motorway for 15 miles before crashing.
A court heart Wayne Thompson was foaming at the mouth as he opened the door of his Vauxhall Astra and stuck his leg out as he drove at high speed.
Leeds Crown Court heard drivers had to brake or swerve out of his path to avoid a crash as the 31-year-old drove through West Yorkshire.
Louise Pryke, prosecuting, said one driver dialled 999 and followed Thompson as he continued to drive erratically.
She said: "As he was swerving backwards and forward across the lanes the defendant kept opening the driver's door and sticking his leg out."
Thompson collided with the central reservation but continued driving.
He left the motorway at the Elland turn off but failed to stop when he reached Blackley roundabout.
Thompson collided with a Toyota Yaris in which three people were travelling.
The Yaris then struck a telegraph pole and was so badly damaged that it had to be written off. No one inside the car was injured.
Thompson carried on driving but came to a stop when he collided with a fence.
The man who had been following Thompson got out of his car and told the defendant to stay at the scene.
Miss Pryke said Thompson was foaming and the mouth and was not making sense when he spoke.
Thompson said: "I have done nothing wrong but my girlfriend has been cheating on me."
He tried to run off when police arrived but was detained by officers.
Thompson, of Holland Court, Radcliffe, Manchester, initially claimed to have blacked out during the incident then refused to comment.
He pleaded guilty to dangerous driving.
Thompson had no legal representation at the court hearing, claiming he could not afford any.
The court heard he has no previous conditions and there was no evidence that he suffered from any personality disorders.
Thompson told the court he was sorry for what happened.
He said: "I was having paranoia and stuff like that."
The defendant said he had a job unloading vehicles for courier firm DHL.
Judge Penelope Belcher jailed Thompson for eight months and banned him from driving for 16 months.
The judge said: "There is no confirmation that there is any personality disorder.
"Nor does it appear that your girlfriend was in fact cheating on you.
"Even if she was, it doesn't even begin to excuse what happened here.
"It is an appalling, prolonged piece of driving."