An off-duty city corrections officer was arraigned on a second-degree murder charge late Thursday for allegedly gunning down his uncle during a family dispute on the Upper West Side.

Cardell Gadsden, 30, who was also charged with criminal use of a firearm, was ordered held without bail in the New Year’s Day shooting death of Steven Gadsden, 37.

Assistant District Attorney Alfred Peterson said an eyewitness overheard the victim’s last words: “Cardell just shot me. Cardell just killed me. Tell my kids I love them.”

The two got into an argument inside a car on Manhattan Avenue and West 107th St. around 9:45 p.m. Wednesday, police said.

The dispute escalated and spilled out onto the sidewalk, where police say Cardell fired a shot into his uncle’s chest and walked away.

He was arraigned in Manhattan Criminal Court before Judge James Clynes.

Cardell returned to the scene shortly after the shooting and surrendered.

Defense attorney Peter Troxler said delayed requesting bail for his client.

A third man who had been in the vehicle was not charged.