Buildings at more than one in six schools in England require urgent repairs, a Guardian investigation has found, leading to warnings that they are “crumbling around teachers and pupils”.

Almost 4,000 schools across the country have been judged by surveyors to be in need of immediate restoration work, and many more were found not to have the paperwork required by law, including electrical test certificates, fire risk assessments or asbestos management plans.

According to data gathered through a government programme to assess the condition of England’s schools estate, 17% (3,731) were found to have buildings with “elements”, such as a roof, wall or window deemed in need of immediate replacement or repair.

Of the 21,796 schools for which information was released, 1,313 had elements that were given the worst possible condition grade D, defined as “life expired and/or serious risk of imminent failure”. Seven hundred and five schools had more than two elements awarded a grade D, while 69 had more than 10.

The data, which was obtained though freedom of information requests, were gathered through the Department for Education’s school condition data collection (CDC) programme, launched in early 2017. As part of the scheme, surveyors visited every government-maintained school in England to collect data about the physical condition of school buildings and how they are managed.

Schools were also asked to fill in a survey before the surveyor’s visit to provide information about its buildings. According to FOI data, 2,939 schools – 14% of the 20,854 respondents – did not have an asbestos management plan; 2,717 (13%) did not have a fire risk assessment; 2,215 (11%) did not have a gas safety test report; and 2,098 (10%) did not have an electrical test certificate.

The Department for Education (DfE) said that in some cases the documentation could have been held off-site by the multiacademy trust managing the school. However, a spokesperson for the National Education Union (NEU) said such paperwork was pointless if it was not held within the building it related to for staff to refer to.

Critics said the findings pointed to a system in which overstretched school leaders were struggling to keep their buildings safe after years of budget cuts. Kevin Courtney, the joint general secretary of the NEU, said the figures highlighted the effect of failure to invest in a crumbling educational infrastructure and that teachers, other staff and pupils deserved better.

He added: “It makes no sense for important practical documents, required by law, not to be held on the premises of a school or college. The reason the government gives – that they may be held by a multi-academy trust would be laughable if it weren’t so serious. If they are missing how can the risk be safely managed?”

Facebook Twitter Pinterest In 2017, the National Audit Office warned the condition of schools was worsening. Photograph: Roger Coulam/Alamy Stock Photo

Teachers across England told the Guardian they were having to work in buildings so cold they had to keep their coats on, with damp walls and infestations of vermin. One teacher in a primary school in Teesside said she worked in a 26-year-old portable building with windows that would not open and others that would not close.

“There is a horrendous cold draft, so I often have to sit with my coat on with the children coming in,” she said. “We had to shut for a week last year because of a massive rat infestation.”

She helped to fix a leak in her classroom because the school could not afford to call a plumber. “I know the state of the school budget and I know that lots of schools in the area have faced restructuring and redundancies and I don’t want us to become one of them,” she added.

Angela Rayner, the shadow education secretary, said schools across the country were in dire need of repair, but the funding was not available. “That failure to invest has left our children and hard working school staff at risk, trying to teach in buildings that are crumbling around them,” she said. Labour has pledged to spend £7bn on repairs and upgrades to school buildings in England.

Upon arriving in office in 2010, the Conservatives scrapped the previous Labour government’s Building Schools for the Future scheme, a £55bn programme to rebuild every secondary school in England. By 2017, the National Audit Office (NAO) warned the condition of schools was worsening, with about 40% of the schools estate built between 1945 and 1976 coming up for replacement or major refurbishment.

The NAO estimated it would cost £6.7bn to bring existing school buildings up to a satisfactory standard, a figure that was expected to double over the course of five years to 2020-21.

In a survey conducted by the NEU last month, 47% of members said the school or college buildings they worked in were not fit for purpose, with 65% blaming funding cuts. Twenty-two per cent said the condition of the buildings had lead to an unsafe environment for pupils and staff.

The issue of health and safety in schools was highlighted in July when the Guardian revealed that nearly 700 had been referred to the Health and Safety Executive (HSE) over concerns they were failing to safely manage asbestos in their buildings.

Lucie Stephens has campaigned for asbestos to be removed from school buildings since her mother, Sue, a former teacher, died of the asbestos-caused cancer mesothelioma in 2016. She said the discovery that more than one in 10 schools did not have the legally required documents on site was horrifying.

Stephens has launched a website that aims to show parents and pupils that schools contain asbestos, but has accused the DfE of a lack of transparency for refusing to release the necessary data. The HSE advises that asbestos is only a risk if it is disturbed or damaged, which releases fibres into the air.

Responding to the findings, the schools minister Nick Gibb said: “The Conservative government provides money annually to improve the condition of school buildings. In this academic year, over £1bn has been made available. We also recently announced a £400m fund for schools to improve their buildings.

“A Conservative majority government would build on that record with £14bn over the next three years, and by increasing the minimum level of per pupil funding in primary and secondary schools.”

• This article was amended on 9 December 2019. And earlier version referred in the headline and text to “nearly one in five”, rather than “more than one in six”, schools. The main image was also changed to better illustrate the text.