The council said not all absentees had been confirmed as having the bug.

Pupils and staff have been advised to stay home for 48 hours after recovering from symptoms of the bug.

A council spokesman said: “Following instances of children showing symptoms of vomiting and high temperature, we can confirm that 415 pupils from Ysgol Brynrefail were absent from school today.

“Some parents have contacted the school to explain that they have chosen to keep their children home from school today as a precautionary measure.

“The school is working closely with the council’s education department and Public Health Wales to deal with the situation. Ysgol Brynrefail remains open, but staff and pupils have been advised not to attend school if they have symptoms of vomiting and high temperature, and to stay at home for 48 hours after symptoms have subsided.

“Anyone with symptoms of vomiting and high temperature should wash their hands after using the toilet and avoid preparing food to prevent the spread of infection to others.

“Public Health Wales has advised that anyone who has been unwell with severe symptoms should contact their GP or NHS Direct on 0845 46 47.”