A gambling addicted Suffolk pensioner who defrauded taxpayers of more than £76,000 has narrowly avoided prison despite a judge telling him he “deserved” it.

Terrence Thomas Freeland, 66, was told by an Ipswich Crown Court judge on Wednesday that had he not pleaded guilty to VAT fraud from the outset he would have been facing two-and-a-half years in prison.

“I read you are mortally terrified of being put in custody,” said Judge David Goodin. “Well you came extremely close to it today by your own dishonesty.”

Freeland, of Mill Road, Badingham, should have paid a total of £77,375 in VAT between April and December 2011. Instead, all but two “derisory” payments of £375 and £370, were filed as “nil return”, leaving a shortfall of £76,630, which he had gambled away, the court heard. A series of previous convictions, the most recent of which had resulted in a suspended sentence for benefit fraud in 2008, were also brought before the court. “On the face of it he has acted dishonestly for a considerable period of time,” said Robert Sadd, prosecuting.

Jeremy Rendle, for the defence, highlighted the “crude” nature of the fraud, which he suggested was not professionally planned.

Freeland was said to have transferred scrap metal to a company and failed to pass on the VAT he was paid.

Mr Rendle suggested the fraud was “exclusively motivated” by his gambling addiction, from which he was now recovering. He also highlighted Freeman’s remorse, ill-health and his role as sole carer for his adult son as grounds for mitigation.

Judge Goodin told Freeland he “deserved to go straight to prison” and had a criminal record “spattered with dishonesty”. However, he said he had been “narrowly persuaded” by the defence.

He sentenced Freeland to 20 months suspended for two years and issued a “punitive” six month curfew confining him to his home between 6pm and 6am each day.