A former FDNY paramedic has pleaded guilty to distributing child porn.

Aaron Aguirre sat shaking in the pews at Brooklyn federal court Tuesday, holding hands with a teary-eyed woman, before he copped to the single charge and was taken into custody.

“I possessed pornographic images on my computer,” the 34-year-old said nervously, stopping short of admitting those images and videos were of toddlers and children aged 4 to 8, as prosecutors claimed.

Federal court Justice William Kuntz II did not require him to elaborate.

Aguirre was busted last February after chatting online with an undercover agent and communicating a “sexual interest” in a child he believed to be the agent’s 5-year-old daughter — who was also on the autism spectrum.

The ex-paramedic managed to remain on the city’s payroll after his indictment, and pulled in nearly $100,000 during the last fiscal year.

Defense attorney Oliver Storch stated last month during a hearing that his client — who he described as “not a public officer” — would not be canned immediately upon conviction.

Yet Storch handed up a letter detailing Aguirre’s resignation Tuesday. He resigned on Monday, the day before the guilty plea, the FDNY confirmed.

The lawyer attempted to argue that revoking his client’s bail before sentencing would be disastrous, whining that the former first responder would “languish” in jail without counseling.

Yet Kuntz, who did not set a sentencing date, ordered him into custody anyway.

Aguirre faces up to 20 years behind bars.