Estimated reading time : 2 min · Published October 4, 2026
Inventory files by purpose
Start with public pages and follow their includes, stylesheets, scripts and datasets. Add routes defined in server configuration and files loaded from calculated names. A photograph may be selected through a catalogue without appearing directly in the page code.
In a PHP project, include and require load other files, so a folder named scripts may contain essential code. Preserve configuration, secrets, keys and access settings. Generated files, such as translation dictionaries or image manifests, may also be needed on every page view.
Choose deletions you can explain
For each candidate, record its purpose, the references checked and the reason for removal. Audit screenshots and local reports are often candidates; an optimized image or font needs further checking. Compare the contents of copies before treating them as duplicates.
A missing literal reference does not prove that a file is unused: examine assembled paths, JSON lists and responsive variants. Work in small groups on a restorable copy. Keep a file when its dependencies remain uncertain and record what is needed to decide.
Verify and deliver a clean project
After each group is removed, open the main page families in every language. Check images, downloads, fonts, the sitemap, feeds and interactive features. Compare the results with the behaviour observed before cleanup, on a phone and a computer.
Record the file count, completed checks and limitations. Store backups outside the public root with suitable protection. Delete temporary verification files and stop test servers; production content, data and dependencies remain in the project.
Reference documents
Content updated on October 4, 2026
