Police raided 43-year-old John Nicholson's Dundee home in February following a tip-off.
Officers found drugs including more than 2.5 kg of heroin with a street value of £263,000 during the operation.
Nicholson will be sentenced on 11 May after admitting being concerned in the supply of drugs at his home in the city's Raglan Street.
Defence counsel Ronnie Renucci said Nicholson pled guilty on the basis that he had allowed his house to be used for the storage of the drugs.
Mr Renucci said: "He was not the owner of the drugs. He was doing so to pay off a debt."
The High Court in Edinburgh was told police officers also recovered £100,000 worth of amphetamine and cannabis with a potential street value of between £60,000 and £90,000.
The court heard that Nicholson had previous convictions for road traffic offences and dishonesty but had never been jailed.
Lord Kinclaven deferred sentence on Nicholson for reports and remanded him in custody.
A man stored £450,000 worth of heroin, cannabis and amphetamines at his house to pay off a debt, a court was told.