Defence lawyer Daniel Schellenberg said his client's problems began in October 2014 when he met a 12-year-old girl through online dating site "Tagged".
The pair began a sexual relationship and though Gill believed she was over 16 initially, they carried on seeing each other after she had revealed her age.
"This offending really represents a significant fall from grace," Mr Schellenberg said.
"[It] really was naive and foolish. He's remorseful and ashamed of himself."
When the 12-year-old's mum went to police, officers seized Gill's cellphone where they found much more than just incriminating messages between him the victim.
On the phone were two objectionable videos, one of which depicted a 50-year-old man raping a 10-year-old child.
And they also found two photos of an adult female body with no head in "what appears to be a murder scene".
Another picture showed the severed head with an Asian male crouching next to it, the summary of facts said.
Gill was later charged with corrupting a witness too after messaging the girl on Facebook about the allegations against him.
"I always pray that ur mom will withdraw the case lol," he wrote in one.
"do u think u can save me in court if I go to trial?" another said.
In February 2015 the pair also secretly met in Onehunga where the victim showed Gill her mother's police statement.
Judge Christopher Field jailed him for two years five months but noted his impending parole eligibility would see him returned to India shortly.
"This experience will affect him for the rest of his life," his lawyer said. "He's learned this type of behaviour is simply unacceptable."