Judge Neil Rafferty made the comment as he jailed Co Londonderry man Christopher Joseph Quinn for 12 months.
Coleraine Crown Court heard the paedophile was “absolutely terrified of going to jail” and was ashamed of himself.
The 57-year-old, of Church Way, Maghera, admitted a string of charges including sexual communication and attempted sexual communication with a child between March and July 2020.
Judge Rafferty said the offending was uncovered by the child’s mother when she accessed her daughter’s social media account.
“The mother took over the conversations and then brought them to the attention of the police in West Yorkshire”, he said.
Judge Rafferty said the social media comments posted by Quinn became more and more sexualised and he used his social media profiles of Irish Trucker and Horny Old Goat.
West Yorkshire Police tracked the messages to Quinn who after he was arrested told the police he was “disgusted and ashamed” by his actions.
He told the police he’d committed the offences “due to the lockdown during the pandemic”.
Defence barrister Eoghan Devlin said Quinn was “absolutely terrified of going to prison” and made full admissions at the earliest possible time.
He said Quinn had informed his family who, while not condoning his actions, were supportive of him.
Mr Devlin said the relevant safeguarding issues had been put in place in relation to Quinn’s children.
Judge Rafferty told Quinn his offending ‘clearly’ justifies a custodial sentence.
Addressing the mother of Quinn’s victim who watched and listened to the sentencing hearing via video link, Judge Rafferty said: “I want to take time to acknowledge what you did and how you did it. It is quite clear that your concerns were absolutely well placed and that your thought process was entirely protective of your daughter and that the calm way that you dealt with that situation was probably the best for your daughter and the best in terms of the gathering of evidence for a criminal prosecution.
“The protective measures of a good and loving parent should not be under estimated as our children encounter the internet and social media. I acknowledge what you did and I thank you”, he said.
Quinn also admitted four charges of an adult causing a child under 13 to look at an image of a person engaging in sexual activity.
He also admitted attempting to incite another to take an indecent photograph of a child and attempting to incite the distribution of an indecent photograph of a child.
In addition to the jail sentence, the Maghera man was placed on the sex offenders register for 10 years and sexual offences protection order (SOPO) imposed for a similar period.
Under the terms of the SOPO Quinn is banned, unless approved by his designated risk manager, from any access to children under the age of 16, unless accidental, and banned from entering into any relationship without full disclosure of his criminality.
He is also banned from engaging in any activity which gives him access to children, banned from using a mobile phone and banned from possessing any internet enabled device. He must also give the police unrestricted assess to his home following his prison release.