A court heard that the youngster – regarded as 'vulnerable' – had been groomed by the convicted pervert and had been at the home for several weeks before he was discovered.
Thankfully, the boy was unharmed after the police rescue.
He was found at the home of Adam Younger, a convicted paedophile who was the subject of an order limiting his contact with young people following three convictions.
When officers called, Younger, 22, fled, then sent the boy a text saying: "Run" - followed by another which read: "Say you have only been for 10 minutes."
Prosecutor Mark Styles told the court Younger had answered the door of his home in Horden, County Durham, partially dressed.
One officer found unmade bedding in a bedroom and saw a cupboard locked by a latch from the outside.
Mr Styles said: "On opening it she found a boy hiding inside."
Younger - who was previously jailed for downloading indecent images, and convicted of sex assaults on boys under 13 - was arrested later that day.
He told poloice he had befriended the boy at a bus station. He admitted child abduction and breaching a Sexual Offences Prevention Order at Durham Crown Court.
Recorder Ian Atherton said it appeared Younger was 'grooming' the boy and jailed him for three years. Warren Grier, mitigating, said: "He needs assistance from a sex treatment programme."