New Jersey’s judiciary is helping the state police do background checks on gun-permit applicants who may be ineligible due to mental-health problems.

The Administrative Office of the Courts has handed over 413,000 records of people who have been involuntarily committed to a mental health institution or who have been found by a judge to be a danger to themselves or others, Chief Justice Stuart Rabner said Thursday.

The state police forward the information to the National Instant Criminal Background Check System (NICS), run by the Federal Bureau of Investigation.

The information is gleaned from the AOC’s Civil Commitment Automated Tracking System, which was developed with an $860,331 grant from the 2008 federal NICS Improvement Amendment Act.

An additional $2.7 million grant from the federal government enabled the courts to enter into the database about 623,000 cases, filed in all 21 counties from 1975 to today.

In New Jersey, civil-commitment records are generally confidential and should not be disclosed, but 2010 amendments to the protective statute, N.J.S.A. 30:4-24-3, allow disclosure to comply with the data reporting provisions of the NICS Improvement Amendments Act and the federal Brady Handgun Violence Prevention Act of 1993.

Recently enacted New Jersey legislation will allow disclosure of information about people who voluntarily seek admission to mental health facilities. The law, A-3717, was passed by the Legislature with only token opposition from a handful of Republicans and was signed by Gov. Chris Christie on Aug. 8.

The law makes the exchange of information mandatory and includes the requirement that information on voluntary commitments be shared.

There also was no vocal opposition to that legislation from the two major organizations in New Jersey supporting gun owners, the National Rifle Association and the Association of New Jersey Rifle and Pistol Clubs.

Voluntary commitments are considered a prohibition against owning firearms in New Jersey, but not at the federal level or at all other state levels.

“We can forward the information that is in our system regarding voluntary commitments in state facilities. It will not necessarily be a prohibitor in other states,” AOC spokeswoman Tamara Kendig said.

A-3717 was part of a package of anti-gun legislation introduced after the shooting deaths of 20 elementary schoolchildren in Newtown, Conn., last December.

Ceasefire New Jersey, an anti-violence group that supports gun restrictions, supports the judiciary’s program, says its director, Nicola Bocour.

“It’s important that we keep guns from getting into the wrong hands,” she says. “This is especially important in helping to prevent suicides.”

Neither the NRA nor the rifle and pistol clubs association immediately responded to requests for comment about the information sharing program.