A former correction officer on Rikers Island was sentenced to 30 years in prison on Wednesday for violating the civil rights of a seriously ill inmate who died after the officer, Brian Coll, kicked him repeatedly in the head while other officers held him facedown on the floor.

“This was a particularly vicious and callous attack, and that’s what makes it such a serious offense,” Judge Loretta A. Preska of Federal District Court said before imposing the sentence.

The inmate, Ronald Spear, 52, had been a pretrial detainee in an infirmary unit at Rikers at the time of his killing in December 2012. Prosecutors have said that Mr. Spear had diabetes, heart disease and end-stage renal disease that required dialysis. He used a cane to walk and wore a bracelet that said he was at “risk of fall.”

Mr. Coll, 48, and Mr. Spear had gotten into a dispute, prosecutors showed at Mr. Coll’s trial last December. Another officer, Anthony Torres, who cooperated with the government, testified that he tackled Mr. Spear and with the help of another guard, Byron Taylor, pinned him to the floor.