The Muslim parents say it would be a sin for their daughter's head to be uncovered while in the presence of male teachers.
And they were so annoyed when she was prevented from wearing the traditional Muslim hijab they withdrew her.
But according to the head teacher of St Cyprian's Greek Orthodox Primary School in Thornton Heath, south London, the ban is standard uniform policy and the parents were fully aware of it when their daughter joined the school from another when she was seven years old.
The child's brother remains a pupil at the school. Head teacher Kate Magliocco said: "The school is being taken to the High Court by parents of a Muslim girl. They believe that, because she is nine, she has reached puberty and it would be a sin for her not to be covered because the school has male teachers.
"The decision not to allow her to wear a headscarf was taken by the governing body.
"The school has a very particular uniform policy, which is shared with parents and, as head, I must follow the plan. The pupil in question came to us from a private school.
"Her parents actively chose us and, before she arrived, we held a meeting which included details of the uniform plan."
She added: "They are a really nice family and it is a regrettable situation for both sides."
The uniform policy on the school website requires girls to wear a dark blue coat, an optional blazer, a skirt, white blouse and a navy blue pullover, but it does not mention a ban on headscarves.
A court hearing is due to take place next month.
More:Advice And Health
Suggested For You
Get top stories and blog posts emailed to me each day. Newsletters may offer personalized content or advertisements. Learn more