The woman in her 30s, who lives on the coast near Cardiff, was given an 18-month jail sentence in July after her children reported her to social services.
She admitted to slapping her 15-year-old son during an argument in 2010, banging two of her sons' heads together for fighting, and slapping two of her sons in 2003.
After pleading guilty to four counts of cruelty to a person under 16, she was imprisoned by Judge David Wynn Morgan at Cardiff Crown Court.
She has now been released by judges at London's Criminal Appeals Court, having spent five months in prison, as 'no valuable purpose would be served by keeping her in prison any longer'.
Today, the Criminal Appeal Court heard that the mother, whose partner had left her, inflicted 'excessive chastisement' on two of her sons four times over seven years.
Appeal judges Lord Justice Elias, Mr Justice Coulson and Mrs Justice Thirlwall, ruled that Judge Morgan had 'taken his eye off the ball' when he sentenced her, and ordered she be freed immediately.
The mother's barrister, Ruth Smith, told the court she was arrested and brought before the courts after one of her sons made a false allegation to social services that she had attacked him, causing bruising.
The child later admitted that was a lie he had told in order to get more contact with his estranged father.
During their investigation, however, it came to light that she had slapped her 15-year-old son in the face during an argument in 2010, had banged two of her sons heads together for fighting, and had slapped two of her sons in 2003.
Miss Smith told the court that the mother 'couldn't cope' with her children and said the only injury she had ever caused was a bruised ear on one occasion.
She added that there was 'clear evidence she had been a victim of domestic violence' herself.
Freeing her, Lord Justice Elias said:
An offender must be sentenced only for what she has been found guilty of. This was plainly an unhappy home... (but) she is not being sentenced for being a bad mother or an incapable mother or of being incapable of controlling her children.
"Only one of these offences caused physical injury. The other incidents are similar to actions taken by many loving and caring parents throughout the land in moments of stress. They may regret it afterwards, but parenting is a difficult skill.
"It is said that the judge gave insufficient weight to her previous good character and was unjust in saying that she had shown no remorse, because there was evidence she was very upset at the time.
"It is also submitted that he was wrong to say that she was minimising her behaviour, because there were occasions when the children had made allegations which had subsequently been disproved.
"We think that the premise of the sentence imposed by the judge was incorrect.
"If he had focused on the particular incidents, only one of which caused physical injury while the others may be seen as chastisement going beyond its bounds, a sentence of 18 months was too long.
"We think the judge took his eye off the ball.
"We think the right thing to do now would be to give her a sentence of five months' imprisonment that would secure her immediate release.
"No valuable purpose would be served by keeping her in prison any longer.'
The law on smacking is a grey area. In Britain, mild smacking by parents is permitted under the defence of 'reasonable chastisement'. The Children's Act sought to clarify this vagueness by making any hitting that causes bruising, swelling, cuts, grazes or scratches punishable with up to five years in jail.
While smacking has a social stigma attached to it and is ineffective as a form of 'discipline', surveys have shown that few parents support an outright ban. It appears a ban smacks too much of government meddling in home life.
More on Parentdish:
More:Advice And Health
Suggested For You
SUBSCRIBE AND FOLLOW
Get top stories and blog posts emailed to me each day. Newsletters may offer personalized content or advertisements.Learn more