Fox News legal analyst Andrew Napolitano said Thursday that President Trump’s appointee to be acting attorney general “does not qualify under the law” to lead the Justice Department.

Napolitano’s comment came a day after the president fired Jeff Sessions and named Matthew Whitaker as the country’s acting top law enforcement official — moves that Napolitano called “nefarious” on Wednesday.

On Thursday, he went further, explaining on “Fox & Friends” why Whitaker, a staunch critic of special counsel Robert Mueller’s Russia probe, should not have been appointed.

“There’s only three ways a person can become acting attorney general. One, if you are the deputy attorney general — Rod Rosenstein — the president signs an executive order and makes you acting,” he said.

“Two is if you are already in the Department of Justice and have a job that requires Senate confirmation and you have received confirmation. That is not the case with Matt Whitaker because he’s the chief of staff. That does not require Senate confirmation,” Napolitano continued.

Whitaker was Session’s chief of staff.

“Three is a recess appointment, which is not relevant here because the Senate is not in recess. So with deference and respect to what the president’s trying to do — he has every right to have whoever he wants run the Justice Department — he has chosen someone who does not qualify under the law to be the acting attorney general,” he added.

Napolitano was a New Jersey Superior Court judge from 1987 to 1995, and has written a number of books on legal issues.