A convicted pedophile from Indiana was busted for trying to have sex with a 14-year-old girl — after walking 351 miles to meet her, according to authorities.

Tommy Lee Jenkins, 32, began an X-rated instant-message exchange with a teen named “Kylee” in Wisconsin who was actually a sheriff’s deputy, according to the US Attorney’s Office.

Jenkins asked her for sexually explicit photographs while badgering her to meet him for sex in Whitestown, Ind., where he lived, officials said.

When she refused, he set off on foot for where she supposedly was, in Neenah, Wis. — repeatedly sending her explicit messages and updating her on the progress of his desperate hike, according to prosecutors.

His mammoth trek ended with a surprise — sheriff’s deputies and an FBI agent waiting to bust him, authorities announced Friday.

Jenkins was charged with using a computer to attempt to persuade, induce or entice a minor to engage in unlawful sexual activity. He faces 10 years to life in prison if convicted.

His messages to “Kylee” included telling her he wanted them to have 500 kids together, including one within a year, according to the Oshkosh Northwestern.

“Our nation faces an epidemic of child sexual abuse, with the internet making it too easy for predators to communicate with children across the country,” said US Attorney Matthew Krueger.

“The Justice Department is committed to working with federal, state, and local law enforcement agencies to prosecute child sexual abuse aggressively.”

Jenkins previously pleaded guilty to child abuse in 2011 for molesting two boys, ages 7 and 8, in Wisconsin, where he used to live, according to the Oshkosh Northwestern.

He was sentenced to four years’ probation with a 360-day jail sentence stayed, the paper said, citing court records.