Jeffrey Baldwin trawled the internet for depraved photos and videos, York Crown Court heard.
Police raided his home in Scarborough and seized a computer tower containing 32 vile images, nearly half of which were rated Category A - the most serious kind.
Baldwin, of Nelson Street, was arrested following the police raid at his former home in Rothbury Street on August 30 last year.
He was charged with three counts of possessing indecent images and two of distributing the vile material between the summer of 2014 and July 2015.
He appeared for sentence on Friday after pleading guilty to all the offences.
Kirstie Watson, prosecuting, told the court that Baldwin had a particular interest in teenage girls but the images featured children across the age spectrum.
She said he had used “peer-to-peer” websites to share files with other paedophiles.
Some of the images involved teenage girls engaging in sex acts with each other.
Ms Watson added that Baldwin had used “cleaning” software in an attempt to hide his browsing history as he scoured the dark web.
Baldwin falsely claimed he had accidentally come across the images while searching for other types of porn.
His solicitor advocate David Camidge said Baldwin’s offending began after he turned to drink following the collapse of his marriage.
But Judge Paul Batty QC described the offences as “revolting” and dismissed Baldwin’s excuses as “frankly risible”.
“It’s perfectly obvious that the search terms you were using indicated a deep-seated obsession with this type of material,” added Mr Batty.
As well as the jail sentence, Baldwin was put on the sex-offenders’ register for seven years and made subject to a sexual-harm prevention order, which will restrict his internet activities and prevent him deleting his search history.