Pupils stepped back in time to celebrate Wootton Bassett Infants School's 150th birthday.
The children, aged from four to seven, dressed in pinafores, cloth bonnets, flat caps and long shorts.
Headteacher Mark Hazzard also got into the spirit by marching up and down the schoolyard inspecting polished shoes, clean hands and fingernails.
"It was a great day. The children have seen another piece of history and seemed to thoroughly enjoy it - I was a bit wary of the children dealing with Victorian discipline but they really rose to the challenge."
The children were given three golden rules to see them through the day: do as you are told immediately, call teachers Sir or Miss, and always stand up when the head enters a room and say good morning Sir'.
The school was founded by Methodists in 1858 and the first head was a Mr Tuck.
During the special day the classroom was transported back to the mid-1800s, the pupils sitting in lines with backs poker-straight.
Pupil Chloe, aged seven, said: "I thought it was really fun but I don't think I would like it every day.
"I really liked dressing up and standing up when Mr Hazzard came in."
The school was at first known as the British School, later coming under local authority control.
It stayed a school for all ages until a secondary school was built in 1958.
A decade later when pupils moved up to Noremarsh Primary School, the name was changed from Wootton Bassett Council School to County Infants.
Youngsters tucked into a cake made in the shape of their school decorated with marzipan pupils from the 1800 and present day.
"The costumes the parents have designed were fantastic," said Mr Hazzard. "They went all out on the theme, way beyond our expectations.
"It was a great day and the teachers are pleased to find that the silence we experienced in classrooms that day seems to have lingered for a while."