John Peter Noble, 36, would scour the internet looking for potential victims and between March and April this year made arrangements to meet with the intention to rape the young child.
Unbeknown to him the child he had arranged to meet was in fact a police officer.
Noble, of North Street, Ripon travelled to meet the child in the North Yorkshire city where instead he was met by undercover police officers from both the force's online abuse and exploitation team and the Yorkshire and Humber Regional Organised Crime Unit (YHROCU).
Noble pleaded guilty to nine child sex offences including arranging to rape a child, sexual assault on a child, arranging to use a sex toy on a child, and arranging for a child to urinate in a glass for his own sexual gratification and consumption, when he appeared at York Crown Court on Monday.
He was given a 14-year sentence which will include 10 years in prison and four years on licence.
The court also heard how he had breached conditions of his Sexual Harm Prevention Order by trying to arrange for the four-year-old girl and a baby to stay over at his home.
The order was issued to him by York Crown Court in September 2019, for indecent images of children, inciting or causing children to perform sexual acts, and sexual communication with a child offences.
Detective Sergeant Lee Allenby, of North Yorkshire Police's online abuse and exploitation team, said: "This was a particularly distressing case where Noble, a man who had already been caught by the police and put before the courts just a couple of years ago, had purchased items for a baby as well as sexual items to facilitate the abuse on the four-year-old girl.
“Noble simply could not resist acting on his sexual deviancy towards children. It is frightening to think that he was actively arranging to rape a child.
“It also showed the lengths of depravity that Noble would go to conduct child sex abuse.
“A long custodial sentence is a pleasing outcome in this case, and it sends a stark warning to other paedophiles who think they can operate with impunity online.”
Detective Inspector Marie Bulmer, from YHROCU, added: "This forms part of our continued priority to protect children from sexual exploitation from those who seek to do them harm.
"Law enforcement operates across the internet, and we will relentlessly seek to bring to justice individuals who use the web to facilitate the abuse of children.
“If anyone has been a victim of child sexual abuse, I urge you to report it to your local police force via 101. We will always follow up allegations of abuse, no matter when they occurred. Victims can talk in confidence to experienced investigators and we can also help them get access to a range of other support services.”