A 15-year-old boy has been charged with kidnapping, raping and murdering an eight-year-old girl whose body was found in a bin in California.

Adrian Jerry Gonzalez is accused of luring Madyson Middleton into his family’s apartment from a courtyard where she had been riding her scooter at the weekend.

Once inside the apartment, he is alleged to have tied up the child, sexually assaulted her and then killed her.

The girl’s body was found in a recycling bin on Monday evening.

Authorities have not been able to establish a possible motive for the killing, it has been reported.

“Unfortunately, the search for Maddy ended in the worst way possible,” said Santa Cruz District Attorney Jeffrey Rosell.

“People do things for lots of reasons, sometimes we understand it, sometimes we don't.”

He said the teenager will be charged as an adult for the alleged crimes, which could see him sent to prison for the rest of his life if he is convicted.

Mr Rosell said he had never seen a 15-year-old charged with murder in his twenty years working in Santa Cruz.

The boy remains in custody at the Santa Cruz County juvenile detention centre.