KATSINA, Nigeria (CNN) -- An appeals court has freed a Nigerian mother sentenced to death by stoning for adultery.
The Shariah Court of Appeal ruled on Thursday that Amina Lawal's conviction was invalid because she was already pregnant when harsh Islamic Shariah law was implemented in her home province.
After the hearing, she told CNN, "I am happy. God is great and he has made this possible. All I want is to go home, get married and live a normal life."
The 31-year-old, who was in court with her baby, Wassila, has been appealing the death sentence for two years.
"It is the view of this court that the judgment of the Upper Shariah Court, Funtua, was very wrong and the appeal of Amina Lawal is hereby discharged and acquitted," judge Ibrahim Maiangwa said.
Shariah law, based on the teachings in the Quran, Islam's holy book, is practiced in 12 of Nigeria's 36 states.
Lawal's case had become the focus of human rights groups around the world who were outraged at the sentence that Lawal should be buried up to her neck and then have stones thrown at her head until she was dead.
Lawal's lawyer, Hauwa Ibrahim, said: "This a great victory for justice. The law of justice has prevailed over the law of man. Amina is free to go, to do what she wants."
But not all the spectators who attended the hearing were pleased by the result. One man who had come to hear to court's ruling said: "I would have preferred Amina to be stoned to death. She deserves it."
Had the court not overturned the verdict, Lawal would still have had two appeals left, one to a Nigerian federal court and a final appeal to Nigeria's Supreme Court. Neither of those courts is governed by Shariah law.
Nigerian President Olusegun Obasanjo had said if Lawal's case reached the Supreme Court, he would make sure it was overturned.
Lawal was convicted and sentenced in March 2002 after giving birth to a baby girl more than nine months after divorcing. Under the strict Shariah law, pregnancy outside marriage constitutes sufficient evidence for a woman to be convicted of adultery.
A court stayed her execution for two years to allow her to care for her baby.
"This is all I have to live for right now," Lawal said before the hearing. "My child means everything to me."
Lawal lives with her father, his two wives and their numerous children in the tiny village of Kurami, deep in Nigeria's Islamic north. The village is so small that it does not appear on a map.
She insists she did nothing wrong and that the man who fathered her child made a promise to marry her. He did not, leaving her pregnant and with no support.
The man said he was not the father, and three male witnesses testified he did not have a sexual relationship with Lawal. The witnesses constituted adequate corroboration of his story under Shariah law, and he was freed.
Lawal is the second woman to be sentenced to death after bearing a child out of marriage since 2000, when more than a dozen states in the predominantly Islamic northern Nigeria adopted strict Islamic Shariah law.
In March 2002, an appeals court reversed a similar sentence on Safiya Hussaini Tungar-Tudu after worldwide pleas for clemency and a warning from Obasanjo that Nigeria faced international isolation over the case.
The adoption of Shariah, which includes amputation as a possible punishment for convicted thieves, has stoked violence between Muslims and Christians in Africa's most populous state. More than 3,000 people have been killed.