A vile former UK scout leader who coerced a likeminded perv to abuse his infant son and installed a hidden camera to film boys using the bathroom has been sent to the slammer for 12 years, according to local authorities — who described him this week as a “professional pedophile.”

Terence Hamblett, 44, who used to run a scouts group in Ellesmere Port, Cheshire, pleaded guilty in November to a string of child sex charges — and returned for sentencing on Thursday, the Cheshire Constabulary said in a statement.

An investigation revealed that Hamblett installed a hidden camera in the the bathrooms of a café he ran at JTF Mega Discount Warehouse in Stoke-on-Trent.

Footage on one of his laptops shows him setting up the camera, and 12 additional clips show two teen boys using the toilet and getting changed.

Investigators learned that Hamblett — who liked to be referred to as “Master” — had been inciting a fellow pedophile to sexually abuse his own infant son on a webcam during their Skype communications over a 3-year-period.

Nearly 14,000 messages — including indecent images — were exchanged between the two men, police said.

Authorities began investigating Hamblett’s alleged actions in September 2016, after receiving information from another police force.

He was arrested on suspicion of possessing, making and distributing indecent images of children.

Police seized several of his devices, which revealed a whopping 922 indecent images and videos of children being sexually exploited, police said.

He also had distributed more than 600 files containing child sexual abuse material — both to other offenders and his victims — through Skype, authorities said.

He pretended to be a teenage boy, and used the Skype names bennyboy4900 and jordbroomy when chatting with the victims, according to police.

He allegedly sent teen boys indecent images and videos in exchange for them performing sexual acts for him on a webcam. But he never showed his face — claiming to have a broken webcam to conceal his true age and identity, police said.

“This was a highly complex investigation involving thousands of images and videos, more than one-and-a-half million Skype messages and the identification of a large number of victims and other offenders both in the UK and abroad,” Detective Constable Andy Kent, of Cheshire Constabulary’s Major Investigation Team, said in the statement. “As a result of the work by our dedicated officers we have been able to show that Hamblett is a professional pedophile who used the internet and social media to sexually exploit vulnerable victims for his own sexual gratification.”