Purvi Patel, 35, was with relatives when she left the Indiana Women's Prison in Indianapolis about 10.00 AM (local time), said Indiana Department of Correction spokesman Doug Garrison.
Her attorney, Lawrence Marshall, said Patel is "very, very joyful that this day has come," but that she now needs privacy so that she can focus on rebuilding her life.
"For right now, she needs to recover from what is obviously a traumatic several years," said Marshall, a Stanford University law professor.
Patel was convicted in 2015 of killing her premature infant by taking abortion-inducing drugs and sentenced to 20 years in prison.
More From This Section
She appealed her feticide and child neglect convictions and the Indiana Court of Appeals vacated both convictions in July, finding that the state's feticide law wasn't meant to be used to prosecute women for their own abortions.
But the appeals court found that Patel should be resentenced on a lower-level child neglect charge that carries a maximum three-year sentence.
Patel was arrested in July 2013 after she sought treatment at a hospital for profuse bleeding.
According to prosecutors, she took abortion-inducing drugs she bought on the Internet and gave birth to a very premature baby boy at her family's home in Granger, a community northeast of South Bend.
Patel was at least 25 weeks into her pregnancy, just beyond the threshold of viability, and the infant took at least one breath before dying, they alleged.