The brothers, 38 and 44, who cannot be named for legal reasons, were also fined 305,000 rupees each ($4,800) according to Senior Superintendent of Chandigarh police, Nilambari Jagadale.
The family of the victim greeted the news with a mix of relief and disappointment, having called on the judge to deliver death sentences.
"The father was of the view that this was the worst kind of crime that can be committed with a small child and the rapists must be hanged," said Alakh Alok Srivastava, the lawyer who represented the victim's family.
With the court cases complete, both the victim and her family are now attempting to return to normalcy, Srivastava said. The victim's baby was placed in the care of Chandigarh's child welfare committee immediately after birth, confirmed Srivastava.
Parole or a reduction in the sentencing of the two brothers is unlikely, said Srivastava.
"We got the baby's DNA tested by our forensic department, and it matched the (sample taken from the) second uncle," Jagadale told CNN in October.
The second, younger uncle was arrested September 19 after the girl named him during a counseling session.
Denied an abortion
Under India's Medical Termination of Pregnancy Act, the country does not permit abortion beyond the first 20 weeks of pregnancy unless the individual is granted special permission from the courts.
The girl's family did not approach the authorities about the pregnancy until the 26th or 27th week, Srivastava told CNN during a previous interview.
The girl's doctor told CNN that she was unaware she was pregnant. Her parents told her she needed surgery for a kidney stone problem, and refused to allow medical professionals to tell their child the truth, said her doctor, who did not wish to be named.
Grim record
India has a grim record of sexual assaults on minors, with 20,000 cases of rape or sexual assaults reported in 2015, according to government data reported by Agence France-Presse.
CNN's Sugam Pokharel contributed to this report.