A couple, who went to bury their newborn at a grave after she died in hospital, discovered the youngster inside an earthen pot buried several feet deep, said a police officer in Bareilly city in northern Uttar Pradesh state.
A woman, who gave her name only as Puja, told local media that she, her husband and brother-in-law called an ambulance after they found the baby dressed in warm clothes inside the pot.
The baby was rushed to a nearby hospital, where she is being given treatment. Police are looking for the parents.
India has seen a dwindling number of girls, according to a government survey released in July, suggesting that illegal abortions of female fetuses continue despite a ban and government efforts to save girl children.
In 2017, police found nearly 20 aborted fetuses dumped in plastic bags in the western state of Maharashtra.