Special Judge Pawan Kumar Tripathi gave the ruling after finding them guilty of rape, murder, abduction and criminal conspiracy over the killing of a 20-year-old woman.
The case, the eighth of the several lodged against them, was registered by the Central Bureau of Investigation or CBI on December 29, 2006.
Koli and Pandher were present in the court during the sentencing.
Prosecution lawyer JP Sharma sought the death sentence and argued that forensic evidence proved that Koli abducted, killed and raped the woman and also tampered with evidence.
Koli lured her inside where she was killed and beheaded. Investigators found her skull behind the house.
Defence lawyer Devraj Singh pleaded for minimum punishment as Pandher suffers from high blood pressure and diabetes.
The gruesome cases came to light in 2006 when the police discovered the skulls and bones of 16 persons, mostly children, near Pandher's house in Noida's Nithari village.
Get Breaking news, live coverage, and Latest News from India and around the world on NDTV.com. Catch all the Live TV action on NDTV 24x7 and NDTV India. Like us on Facebook or follow us on Twitter and Instagram for latest news and live news updates.