The head of New York’s biggest federal credit union was arrested at home by US agents on Tuesday on charges he embezzled more than $6 million — and spent more than half of it on lottery tickets.

The feds charged Kam Wong, the CEO of Municipal Credit Union, with four counts of embezzlement, fraud, wire fraud, and aggravated identity theft for using reimbursement scams for fake dental work, unneeded repairs to his Mercedes Benz and long-term insurance to enrich himself from 2013 to 2018.

In a weird twist, about $3.9 million of the ill-gotten gains allegedly went to fund a “lottery habit” near his office and his home in Valley Stream, Long Island.

Wong, who made more than $684,000 a year, wrote 216 checks to two bodegas and withdrew $1.9 million from ATMs a total of 2,592 times for the lottery tickets — sometimes multiple times a day, according to the complaint.

On weekends, Wong “spent hours … purchasing and playing lottery tickets,” according to the Justice Department complaint filed by Manhattan US attorney Geoffrey S. Berman.

Wong, who has been the CEO since 2007, submitted at least 24 sham invoices for dental he never received as well as for additional money to pay his tax liability, totaling $687,000, according to an unsealed complaint.

While several of the invoices appear to be genuine, the Justice Department alleges others “could not be real” — including some that were submitted when one of his dentists was in the hospital.

The dentists, who are unnamed, aren’t accused of wrongdoing.

MCU, which is the oldest credit union in the state, reimbursed Wong for the expenses — even though it provided him and his family members with dental insurance, according to the complaint.

Wong, 62, also scammed the credit union with a long-term disability insurance scam, according to the complaint.

The CEO had asked the board to forego $1 million in the insurance payments and, instead, pay him $200,000 directly — something the board hadn’t agreed to but which he got anyway, according to the complaint.

Wong then sought out inflated insurance costs from brokers in order to increase the cash payments, as well as the tax liabilities—ending up with about $6.5 million paid to the CEO, according to the complaint.

“If I’m an athlete, I want you as my agent,” the insurance broker told Wong, according to the complaint.

When a federal agent asked Wong about these payments, the exec got the board to “retroactively” approve the payments — an attempt to circumvent an ongoing investigation, the DOJ claims.

Lawyers for Wong weren’t immediately available for comment.