An Uber driver who claimed he was controlled by a "devil figure" on the day he killed six strangers between rides has made a surprise confession, pleading guilty.

Key points: Jason Dalton, 48, says a 'devil figure' on the Uber app was controlling him on the day of the shootings

Jason Dalton, 48, says a 'devil figure' on the Uber app was controlling him on the day of the shootings Despite pleading guilty, Dalton did not explain why he began the random shooting spree

Despite pleading guilty, Dalton did not explain why he began the random shooting spree Dalton's family have released a statement, expressing condolences to the victims' families

Jason Dalton, 48, was charged with six counts of murder over the 2016 weekend shooting spree in and around Kalamazoo, in the US state of Michigan.

Dalton pleaded guilty to murder and attempted murder over his attorney's objections, triggering a mandatory sentence of life in prison with no chance for parole.

"Yes, I've wanted this for quite a while," Dalton replied when a judge asked if the pleas were voluntary.

He answered "yes" to a series of questions, admitting that he shot eight people at three locations.

After his arrest, police quoted Dalton as saying a "devil figure" on Uber's app was controlling him on the day of the shootings.

Four women were killed in the parking lot of a Cracker Barrel restaurant, while a father and his 17-year-old son were fatally shot while looking at a pickup truck in a dealer's lot.

Two others, including a 14-year-old girl who was shot in the head, survived the attack.

Dalton had been deemed competent to stand trial and last week dropped an insanity defence.

In court, he didn't explain why he randomly shot eight people.

Motive behind shootings a question that 'haunts us'

Dalton, the father of two children, had worked as an insurance adjuster and had no previous criminal record before the February 2016 shootings.

Prosecutor Jeff Getting said the motive behind the shootings was a question that "haunts us".

"Everybody wants to know," he said during a news conference after the court hearing.

Defence attorney Eusebio Solis said he advised Dalton not to plead guilty.

"But in speaking to Dalton, there are reasons" for the plea, Mr Solis told Judge Alexander Lipsey.

"There are personal reasons for him. He does not want to put his family through that, or the victims' families, through the trial. It's his decision."

A gun shop owner said Dalton bought a jacket with an inside pocket designed to hold a gun just hours before the rampage.

Shop owner Jon Southwick recalled Dalton "laughing and joking," and giving a "one-armed hug" to the manager before making the purchase.

Dalton's relatives and former wife released a statement, expressing condolences to the victims' families for "this senseless tragedy".

"Nothing that we can say is adequate, but please know that our hearts are broken by the suffering which has resulted from the actions of our son and former husband," the statement said.

AP/ABC