A 13-year-old boy who hid a gun, silencers and ammunition for a fellow gang member at his south-east London home has been detained for 18 months.
Armed police raided his home in New Cross in August 2008 and found a Russian-made Baikal semi-automatic pistol, Inner London Crown Court heard.
The gun and two silencers were wrapped in a pillowcase inside a rucksack.
The Metropolitan Police said he was the youngest child they had arrested for having a gun.
In the months before the discovery, the boy had received two reprimands - one for robbery, the other for threatening behaviour.
He was then made the subject of a six-month referral order after being found with a meat cleaver at school.
Not one of my officers wants to come across a child in possession of a live gun
Det Ch Insp Peter Beyer
Judge Usher Kara told him that, having considered the facts of the case, including his previous brushes with the law and the "complete disregard" he had shown for the help he had been offered, it was clear he was a "persistent offender".
"Gang culture cannot be tolerated," she said.
The boy, now aged 14, admitted several charges of possession.
A barrel brush for cleaning another type of a gun was found in the loft while a machete was recovered from the wardrobe in the youngster's bedroom.
Tests later showed the gun was "clean" and not connected to any known crime.
The search of the boy's home was ordered as part of an eight-month Met investigation targeting gang-related activity in south London.
During interviews, the youngster confessed he was a member of a gang that had not been brought to the attention of police prior to the incident, jurors heard.
He said the gun had been given to him in July by a 19-year-old fellow gang member.
Outside court, Det Ch Insp Peter Beyer said: "This case is extremely sad and deeply concerning and, while we are committed to targeting anyone thought to be in possession of firearms, not one of my officers wants to come across a child in possession of a live gun."
Jurors heard that the boy's parents did not know about their son's activities.
Rhodri James, defending, said: "He has the support of both his parents, who are obviously very anxious about these proceedings."
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.