Man had 4,000 banned pills to help him sleep.
A MAN imported a drug to help him sleep at night, a court heard.
Usman Ali, 27, ordered more than 4,000 Diazepam tablets after spotting them for sale online.
Diazepam is legally available in this country but on prescription only.
The package was intercepted by police when it arrived in the UK from Pakistan.
Ali, of West View, Batley, pleaded guilty to importing a controlled class C drug, when he appeared at Kirklees Magistrates' Court.
He also admitted possessing the drug with intent to supply, after passing it on to family.
James Weekes, prosecuting, said that Ali came to the attention of police on October 29 when a large cardboard box addressed to him was intercepted at Coventry Airport.
The parcel was seized when it was found to contain 4,553 Diazepam tablets.
Police arrested Ali at his home where a number of white envelopes with the drug inside were also found.
Mr Weekes said: "He said he was using various drug hormones and since he had been taking these he had problems with sleeping.
"He thought that Diazepam, or Valium, would help him relax and send him to sleep.
"The defendant said he found an advert on a Facebook page to purchase them."
"He paid PS250 for some 4,000 tablets and was under the impression that the drugs were coming from outside the jurisdiction."
Ali claimed he was unaware that the drugs were illegal and only sent them on to members of his family and friends.
Magistrates committed Ali to Leeds Crown Court for sentence on May 22. He was granted bail.