Inset: Jakayla Ashanti Williams (Dothan Police Department). Background: The landfill in Alabama where the baby's body was recovered (KFYR).

A 21-year-old Alabama woman will spend the rest of her life behind bars for killing her newborn son and leaving his body in a dumpster equipped with a trash compactor, bringing an end to a case that once had prosecutors seeking the death penalty.

Houston County Circuit Judge Henry D. Binford on Monday ordered Jakayla Ashanti Williams to serve life in a state correctional facility without the possibility of parole.

Binford handed down the sentence after Williams accepted an eleventh-hour deal to avoid the possibility of being put to death, pleading guilty to one count of capital murder just moments before jury selection was scheduled to commence, Mobile, Alabama, ABC affiliate WKRG reported.

As Law&Crime previously reported, a then-18-year-old Williams in August 2023 secretly gave birth to the baby at her home in Dothan, Alabama, about 200 miles southeast of Birmingham. She later told family members that she had surrendered the child to a "red-headed" employee at Southeast Health Medical Center.

But her story quickly unraveled.

Williams went to the hospital with a family member days after the birth and claimed she was trying to recover the newborn. Hospital staff contacted police, and investigators reviewed surveillance footage after Williams gave them a vague description of the purported employee who had supposedly taken the child.

Not only did the footage fail to show any employee matching the description provided by Williams, it also did not show any evidence of Williams being at the hospital following the child's birth.

Police questioned Williams again, and she eventually admitted that she had left the newborn in a dumpster at an apartment complex near her home. Investigators found the baby's remains at the Dothan landfill after the dumpster's contents had been transported there. The infant had been wrapped in a mattress protector and placed inside a zipped duffel bag.

Williams told investigators she did not want to be a mother at 18 and that having a baby "cost too much money," police said at the time.

Prosecutors charged Williams with capital murder and eventually announced they would pursue the death penalty. During a 2023 hearing, her defense challenged the state's contention that the baby was alive when Williams put him in the dumpster. Defense attorney Clay Wadsworth also emphasized that Williams was young, had no criminal record, and needed mental-health treatment.

The case remained pending for years as Williams' attorneys pursued a mental-health defense. In the days before trial, her lawyers reportedly argued that her age and emotional condition should be considered as mitigating factors.

"I'm shocked this is the case they chose to seek the death penalty," her defense attorney, Aimee Cobb, told local CBS affiliate WTVY.

The case also prompted city officials in October 2023 to vote in favor of bringing a Safe Haven Baby Box to the city, allowing mothers to surrender newborns safely and anonymously under the state's Safe Haven law. Dothan now has at least three such active boxes, while the state has 24, per WTVY.