Your WordPress uploads folder grows quietly. Every import, every draft image that never made it to a post, every theme change that triggered a batch of regenerated thumbnails: they all stay. Nothing removes them automatically. After a year or two, what started as a tidy directory becomes a storage problem that slows backups, complicates migrations and makes every manual cleanup riskier than it needs to be. The solution is not one big cleanup. It is a 30-minute routine done once a month, before the mess compounds.
Why does your WordPress media library get bloated?
WordPress never deletes a media file unless you tell it to. That design choice protects content, but it means the library accumulates passively: images from revisions that never published, PDFs linked from a page that no longer exists, product photo imports from a WooCommerce catalogue update, and every thumbnail size your theme ever generated, including sizes from a theme you replaced two years ago. Media library bloat is not a sign of mismanagement. It is the default outcome of a system that prioritises preservation over hygiene.
The consequences are practical. WordPress uploads bloated with unused files increase backup size and backup time. Storage costs rise. Migrations get heavier. And when you eventually decide to clean up, a large unaudited library is a minefield: deleting the wrong file breaks a page, and without a clear picture of what is in use, mass deletion becomes a gamble.
The scale compounds faster than most people expect. According to WordPress core documentation, every image uploaded to WordPress generates at least three size variants by default (thumbnail, medium and large), and themes and plugins each register additional sizes on top. A library with 1,000 original images can easily contain 5,000 to 8,000 actual files once all registered sizes are counted. For WooCommerce stores with product variations, that multiplier is higher still. As noted in the WordPress developer handbook, none of these derivative files are removed automatically when you change themes or deactivate a plugin, because WordPress has no mechanism to distinguish âregistered but no longer neededâ from âactively in use.â
A WordPress maintenance checklist done monthly breaks the problem into small, safe increments. Thirty minutes now prevents three hours of stress later.
What you need before you start
The routine has five steps (health check, clean clutter, remove duplicates, set prevention habits, verify), each safe and reversible. Done in order they take around 30 minutes.
Before touching anything, confirm two things: you have a recent backup, and you know your current uploads folder size. If you have a staging environment, run the first cleanup there. For ongoing monthly routines on a stable site, a backup is enough.
The âdonât break pagesâ rule
Never mass-delete in a single action without a prior check. Always move files to the WordPress trash before emptying it, as the trash gives you a recovery window. After any deletion session, verify your key pages before clearing the trash permanently.
Step 1 (5 min): quick health check of your media library
The goal here is to get a clear picture before acting. You are not cleaning yet: you are reading the signals. Checking your media library size and file count takes five minutes and tells you whether this month needs a light pass or a deeper session.
In your WordPress dashboard, go to Media > Library and switch to list view. Sort by date. Look at how many files were added in the past 30 days and whether that volume feels proportionate to the content you published. Then check your uploads folder size in your hosting control panel.
Simple metrics to track each month
Keep a note (a spreadsheet row, a Notion entry, anything) with three numbers recorded at the start of each session:
- Total size of your
/uploadsfolder (visible in your hosting control panel or via a plugin) - Total number of media files currently in the library
- Number of files added since your last cleanup
Tracking these month over month takes 90 seconds and gives you an early warning when something unusual happens: a bulk import, a plugin that auto-generates files, or a WooCommerce variation update that added 400 images at once.
Step 2 (10 min): is it safe to delete unused media?
This step targets the quick wins: files in the trash that were never emptied, media that is clearly unused, images that are unnecessarily large, and non-image files that may no longer serve a purpose. These are the safe actions: low effort, low risk, immediate impact on your uploads folder size.
Start by emptying the WordPress media trash if you have not done so recently. Files in the WordPress trash still occupy disk space until you empty it permanently. This alone can recover meaningful storage on sites that have been running cleanups manually for a while.
Unused media: shortlist, donât mass delete
Unattached media are files not linked to any post or page and the most common source of bloat. But âunattachedâ does not always mean âunused.â A file can be inserted directly into a block or referenced in a custom field without WordPress recording an attachment relationship. That is a structural limitation of how the media library tracks usage. Removing unattached media safely requires knowing which files are genuinely unused, not just technically unattached.
Native WordPress gives you a filter for unattached media in list view. Use it to build a shortlist of candidates. Then, before deleting anything, verify: search the file name in your content, check if it appears in any active page template, and confirm it is not linked from a menu or widget. For a full walkthrough of this process, see how to find unused media in WordPress and how to delete unused media files safely.
This is where Mediapapa changes the process. Rather than a manual cross-check, the usage index scans your content sitewide and maps each file to where it actually appears: posts, pages, templates, custom fields. Files flagged as unused are genuinely unused, not just unattached. The Deletion Warnings feature adds a second layer: if you attempt to delete a file that Mediapapa has identified as in use, it alerts you before the deletion completes. That combination removes the guesswork: proactive scanning identifies genuinely unused files, and Deletion Warnings catch any oversight at the moment of deletion. Together they make it safe to delete unused media with confidence.
Large images: compress or replace, not delete
Large image files deserve a different action than deletion. A 4 MB hero image that is actively used on your homepage should be compressed and converted to a modern format (WebP or AVIF), not removed. WordPressâs image editor handles basic resizing. Mediapapaâs compression handles format conversion and quality optimisation without affecting the original fileâs attachment ID, meaning every place the image is used stays intact.
Check your library filtered by file size. Anything above 1 MB that is not a full-resolution download (a PDF, a print-ready asset) is a candidate for optimisation.
Non-image files (PDF, video, audio): keep it intentional
Scroll through your PDFs, audio files and videos once a month. For each one, ask: is there still a page linking to this? Is the link still accessible to visitors? Video files in particular can sit in uploads long after the post they supported was deleted or redirected.
If you use a lot of PDFs (product sheets, guides, downloadable content), check that the download links on your pages actually resolve. A broken link to a file that still exists in uploads is a minor fix. A broken link to a file that has been deleted is a support ticket.
Step 3 (8 min): how do you find and remove duplicate images?
Duplicate images in WordPress come in two distinct forms, and they require different responses.
True duplicates are multiple uploads of the same original file: the same image uploaded twice under different names, or the same PDF imported once per quarter because no one checked whether it already existed. These are safe to consolidate once confirmed.
Regenerated thumbnail sizes are not duplicates in the traditional sense, but they can look like them. Every WordPress image generates multiple size variants on upload: thumbnail, medium, large, and any sizes registered by your active theme and plugins. When you switch themes or change size settings, new variants are created for existing files. The old ones stay. The result is a large cluster of files that share a name with a numbered suffix (hero-image-300x200.jpg, hero-image-1024x768.jpg), technically distinct but largely redundant.
Quick duplicate checks (small sites)
For small sites with a few hundred media files, a manual scan is workable. In list view, sort by filename. Look for patterns: image.jpg followed immediately by image-1.jpg and image-2.jpg is a strong signal of repeated uploads. Sort by date next and look for clusters of uploads on the same day with similar names, which is the typical trace of a bulk import where files were not checked against the existing library first. Sort by dimensions to identify images that appear to be the same composition at different resolutions.
Note the candidates. Do not delete yet. Cross-reference each one: is the variant in active use somewhere, or is it genuinely redundant? On a small site this takes a few minutes. On a site with thousands of images, the manual process quickly becomes impractical: too many files to cross-check reliably, and too high a risk of removing a file that is in active use somewhere in a template or custom field.
Mediapapaâs duplicate detection surfaces these automatically, comparing file content rather than just names. Where duplicates are confirmed, Safe Replace handles consolidation: it replaces every instance of the duplicate with the canonical file, updating all attachment IDs and URLs sitewide before the redundant copy is deleted. That eliminates the broken-image risk that comes with a manual delete-and-update workflow.
If you redesigned your theme recently: watch regenerated sizes
After a theme change, your uploads folder may have grown significantly without any new content being added, as a direct consequence of WordPress generating new thumbnail variants for your existing library. Check your folder size before and after any theme switch or major customisation change. If regenerated sizes have accumulated, a plugin like Regenerate Thumbnails can help you remove obsolete sizes, but read the documentation before running it, and do so on staging first.
Step 4 (5 min): prevent future bloat
Five habits that reduce the next cleanup to a formality:
Name files before uploading. product-hero-blue-2025.jpg is findable. IMG_4821_FINAL_v3.jpg is not. Consistent naming prevents re-uploads of assets that already exist but cannot be located.
Check before uploading. Before adding a file, run a quick search in the media library. Most duplicate uploads happen because the original file was not found, not because it did not exist.
Keep one canonical version of each asset. When a logo or product image is updated, replace the existing file rather than uploading a new one alongside it. If you use Mediapapa, Safe Replace handles this propagation automatically.
Audit your registered image sizes. Each active plugin and theme registers thumbnail sizes. Check your functions.php or use a plugin to list active sizes. Remove sizes you are not using, as fewer registered sizes means fewer files generated on each new upload.
Set a monthly reminder. The routine only works if it happens. A calendar event set to recur on the first Monday of each month costs nothing and prevents the backlog from rebuilding.
Step 5 (2 min): post-cleanup verification
Before clearing the trash, check five pages:
- Homepage
- Your highest-traffic post or page (check Analytics if you are unsure)
- A category or archive page
- If you run WooCommerce: a product page and the shop page
- The most recent article or page you published
Look for broken image placeholders. If you see one, restore the deleted file from the trash immediately and review your usage check from Step 2. Checking for 404 images after cleanup takes two minutes and prevents a broken experience from going unnoticed.
If your site uses a caching plugin or a CDN, purge the cache after cleanup. Cached pages may still reference old file paths.
The printable checklist
Copy this into your notes app, Notion or a shared doc. Run it once a month.
Before you start
- Backup confirmed (or staging available)
- Current uploads folder size noted
- Current media count noted
Step 1 â Health check (5 min)
- New files added since last session reviewed
- No unusual spikes in file count or folder size
Step 2 â Clean obvious clutter (10 min)
- Unattached media shortlist reviewed and verified before deletion
- Large images (>1 MB) compressed or flagged for compression
- Non-image files (PDF, video, audio) checked for active links
Step 3 â Duplicates and sizes (8 min)
- Duplicate candidates identified and confirmed before removal
- Regenerated sizes reviewed if a theme change occurred this month
Step 4 â Prevention habits (5 min)
- Naming convention applied to any new uploads this month
- Image size registry reviewed (if new plugins were installed)
Step 5 â Post-cleanup verification (2 min)
- Five key pages checked for broken images
- Trash emptied after verification
- Cache purged
If you only have 10 minutes: skip Steps 3 and 4. Run Step 1 to note your metrics, do a quick pass on large images in Step 2, and run Step 5 before closing. The audit is incomplete but the site is safe. Catch Steps 3 and 4 next month.
Curious what is hiding in your library? Scan it for free.
FAQ
Once a month is enough for most sites. High-volume sites, such as active e-commerce stores, news publishers or membership platforms with frequent uploads, may benefit from a fortnightly pass. The key is consistency: small regular sessions are safer and faster than infrequent mass cleanups.
Not automatically. “Unattached” means WordPress has not recorded a formal attachment relationship between the file and a post. It does not mean the file is unused. Files inserted directly into blocks, referenced in custom fields or linked from menus can be unattached but still active. Always verify before deleting, either manually or with a tool that tracks actual sitewide usage.
Most duplicates come from repeated uploads of the same asset, usually because the original could not be found at the time. A second common source is WooCommerce: product variation images are sometimes imported multiple times across catalogue updates. A third source is theme or plugin switches that regenerate thumbnail sizes, which can look like duplicates but are technically distinct files.
Yes, with one distinction worth understanding. Removing unused files does not speed up page loads: those files were never served to visitors in the first place. The performance gains come from the compression and optimisation work you do during cleanup: converting large images to modern formats, reducing file sizes and ensuring every active image is appropriately sized. A well-maintained library is also easier to audit for missing alt text and poor metadata, which does affect SEO. The secondary benefits, faster backups, lower storage costs and cleaner migrations, are consistent and compound over time.
WooCommerce generates multiple image sizes per product (thumbnail, medium, large, and any sizes registered by your theme or plugins). Catalogue imports and variation updates are a common source of bloat. Apply the same routine: check for duplicates after every bulk import, compress large product images before they go live, and review non-image files (data exports, PDFs) periodically. After any import, filter the media library by the import date and scan the file list for repeated filenames before moving on. If you run a large catalogue, consider a fortnightly check after any bulk import rather than waiting for the monthly session.
Additional reading
- Managing media in WordPress â WordPress.org
- Tracking media usage and Deletion Warnings â Mediapapa documentation
- Detecting and removing duplicate images â Mediapapa documentation
- Compressing and optimising images â Mediapapa documentation




