Sharon Shoesmith, the Haringey children’s service boss who was sacked over the shocking death of Baby P has won her case in the Court of Appeal.

Shoesmith was challenging an earlier High Court ruling that cleared regulator Ofsted, former children’s secretary Ed Balls and Haringey Council of acting unlawfully.

The Haringey children’s services director lost her £133,000-a-year job in 2008 after an Ofsted report into Baby P’s death exposed failings in Ms Shoesmith’s department. Shoesmith was then sacked with “immediate effect” in a TV press conference by Balls.

Shoesmith’s lawyers argued that she was the victim of “a flagrant breach of natural justice” and that she lost her £133,000-a-year post because of a “media witchhunt”.

The judges allowed Ms Shoesmith’s appeal against the former children’s secretary because “the secretary of state did not afford Ms Shoesmith the opportunity to put her case”.

In the case of Haringey, the judges said: “We were unanimously of the view that Haringey’s procedures were tainted by unfairness.”

17 month old Baby Peter Connelly was found dead in August 2007 with more than 50 injuries.

His mother Tracey Connelly, and her lodger Jason Owen were later jailed for his death.

Speaking outside court, Ms Shoesmith said: “Having spent a lifetime protecting, caring (for) and educating children, my sorrow about the death of Peter Connelly in Haringey when I was director is something which will stay with me for the rest of my life.”

“But as the judges have said, making a ‘public sacrifice’ of an individual will not prevent further tragedies.”

She will now return to the High Court for a compensation hearing to claim backdated salary and pension payments from the day she was dismissed in 2008 up until now.

The Department of Education and Haringey Council are expected to appeal today’s decision at the Supreme Court.