An on-duty FDNY firefighter was arrested for punching an NYPD officer in the face during an unprovoked attack inside a Queens hospital, police said Friday.

The assault happened about 9:50 p.m. Wednesday inside Queens Hospital Center on 164th St. in Jamaica.

Firefighter Abel Sencion, 34, hit Police Officer Philip Vallon, who was also on duty, in the face, according to a criminal complaint charging the suspect with second-degree assault, a felony.

Although it wasn’t immediately clear what happened, police said the attack was unprovoked.

The 32-year-old officer suffered minor pain and swelling but was otherwise uninjured, according to court documents.

Sencion pleaded not guilty at his arraignment Thursday and posted the $5,000 bail a Queens Criminal Court judge set for him. His lawyer could not immediately be reached for comment.

It wasn’t clear why Sencion and Vallon were at the hospital.

Sencion joined the FDNY in 2023 and was assigned to Engine Company 277 in Bushwick, Brooklyn, according to city records.

FDNY officials said Sencion will be suspended from duty for 28 days as a result of his arrest.