❌

Normal view

[PROMO] Unused Media - shows where each file is actually used, not just "Unattached"

21 September 2026 at 04:56

(Free, GPL, on wordpress.org: https://wordpress.org/plugins/freshet-unused-media/)

What it does: adds a Usage column to the Media library and, per file, lists every place in the database that still refers to it.

I wrote it because WordPress doesn't know.
Core's "Unattached" filter records one thing: the post you had open when you uploaded.

This has been discussed at great length (my favourite thread on the subject: https://www.reddit.com/r/Wordpress/comments/1j2nagv/how\_to\_clean\_up\_images\_in\_media\_library/) and the verdict is basically always the same: it's tricky.

Where mine differs: it's slow, it's one-directional, and it never tries to prove a file unused. Any ambiguity counts as used.

If you deal with larger, older sites with unruly libraries, pull a local copy and test it, or run it on WP's Playground:
https://playground.wordpress.net/?blueprint-url=https%3A%2F%2Ffreshet.studio%2Fplayground%2Ffreshet-unused-media.json%3Futm_source%3Dreddit%26utm_medium%3Dwordpress

An audit, with numbers, is on my blog:
https://freshet.studio/blog/how-to-find-unused-media-in-wordpress?utm_source=reddit&utm_medium=wordpress

Feedback wanted, especially: a place references hide that the list below misses, and whether the per-file evidence is enough for you to trust a delete.

  • post content (every generated size and the -scaled variant)
  • postmeta
  • ACF fields
  • block markup that stores only the attachment ID
  • options and theme mods
  • widgets
  • term meta and user meta
  • comments and autosaves

Thanks everyone!

submitted by /u/serifoblique
[link] [comments]
❌