{"id":248642,"date":"2025-12-29T23:50:32","date_gmt":"2025-12-29T23:50:32","guid":{"rendered":"https:\/\/wordpress.org\/plugins\/cleanup-orphan-images\/"},"modified":"2026-05-23T04:25:55","modified_gmt":"2026-05-23T04:25:55","slug":"cleanup-orphan-images","status":"publish","type":"plugin","link":"https:\/\/de-ch.wordpress.org\/plugins\/cleanup-orphan-images\/","author":7482918,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"1.8.1","stable_tag":"1.8.1","tested":"7.0","requires":"5.0","requires_php":"7.4","requires_plugins":null,"header_name":"Cleanup Orphan Images","header_author":"Manly Electronics","header_description":"Finds and deletes unattached images and orphan files from the uploads directory.","assets_banners_color":"f9f9fa","last_updated":"2026-05-23 04:25:55","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"","header_author_uri":"https:\/\/manlyelectronics.com.au","rating":5,"author_block_rating":0,"active_installs":70,"downloads":668,"num_ratings":1,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.7.1":{"tag":"1.7.1","author":"DimitriAus","date":"2025-12-29 23:50:01"},"1.7.2":{"tag":"1.7.2","author":"DimitriAus","date":"2026-01-02 10:11:53"},"1.8.0":{"tag":"1.8.0","author":"DimitriAus","date":"2026-01-07 12:25:48"},"1.8.1":{"tag":"1.8.1","author":"DimitriAus","date":"2026-05-23 04:25:55"}},"upgrade_notice":[],"ratings":{"1":0,"2":0,"3":0,"4":0,"5":1},"assets_icons":{"icon-256x256.png":{"filename":"icon-256x256.png","revision":3429958,"resolution":"256x256","location":"assets","locale":"","width":225,"height":225}},"assets_banners":{"banner-772x250.png":{"filename":"banner-772x250.png","revision":3431993,"resolution":"772x250","location":"assets","locale":"","width":772,"height":250}},"assets_blueprints":{},"all_blocks":[],"tagged_versions":["1.7.1","1.7.2","1.8.0","1.8.1"],"block_files":[],"assets_screenshots":[],"screenshots":[]},"plugin_section":[],"plugin_tags":[3786,88,163,84,17741],"plugin_category":[50],"plugin_contributors":[253003],"plugin_business_model":[],"class_list":["post-248642","plugin","type-plugin","status-publish","hentry","plugin_tags-cleanup","plugin_tags-files","plugin_tags-images","plugin_tags-media","plugin_tags-orphan","plugin_category-media","plugin_contributors-dimitriaus","plugin_committers-dimitriaus"],"banners":{"banner":"https:\/\/ps.w.org\/cleanup-orphan-images\/assets\/banner-772x250.png?rev=3431993","banner_2x":false,"banner_rtl":false,"banner_2x_rtl":false},"icons":{"svg":false,"icon":"https:\/\/ps.w.org\/cleanup-orphan-images\/assets\/icon-256x256.png?rev=3429958","icon_2x":"https:\/\/ps.w.org\/cleanup-orphan-images\/assets\/icon-256x256.png?rev=3429958","generated":false},"screenshots":[],"raw_content":"<!--section=description-->\n<p>Removes files left in the uploads folder that are invisible in the WordPress Media Library. This does not include Unattached media, which can be easily found and removed in the standard Media Library.<\/p>\n\n<p>These orphan files may have been left behind from:<\/p>\n\n<ul>\n<li>Failed or interrupted uploads<\/li>\n<li>Plugin operations or migrations<\/li>\n<li>FTP\/SFTP uploads not registered in WordPress<\/li>\n<li>Database restores or imports<\/li>\n<\/ul>\n\n<h4>Features<\/h4>\n\n<ul>\n<li>Scans uploads directory for orphan media files<\/li>\n<li>Supports images: JPG, JPEG, PNG, GIF, WebP, BMP, TIFF, SVG, ICO<\/li>\n<li>Supports documents: PDF, DOC, DOCX, XLS, XLSX, PPT, PPTX, ODT, ODS, ODP, TXT, RTF, CSV<\/li>\n<li>Supports audio: MP3, WAV, OGG, FLAC, AAC, M4A, WMA<\/li>\n<li>Supports video: MP4, MOV, AVI, WMV, MKV, WebM, FLV, M4V, MPEG, MPG<\/li>\n<li>Supports archives: ZIP, RAR, 7Z, TAR, GZ<\/li>\n<li>Safe manual selection before deletion<\/li>\n<li>Warns when orphan count exceeds server's max_input_vars limit (typically 1000)<\/li>\n<li>Optimized O(1) performance with hash-based detection<\/li>\n<\/ul>\n\n<h4>Note<\/h4>\n\n<p>This plugin does NOT manage \"unattached\" images in the Media Library. WordPress already provides built-in filtering for unattached media. This plugin focuses specifically on finding physical files that WordPress doesn't know about at all.<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Upload the <code>cleanup-orphan-images<\/code> folder to <code>\/wp-content\/plugins\/<\/code><\/li>\n<li>Activate through the 'Plugins' menu<\/li>\n<li>Go to Media &gt; Cleanup Orphan Images<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id=\"what%20are%20orphan%20files%3F\"><h3>What are orphan files?<\/h3><\/dt>\n<dd><p>Orphan files are physical media files in your uploads folder that exist on the server but are not registered in the WordPress database.<\/p><\/dd>\n<dt id=\"is%20it%20safe%20to%20delete%20orphan%20files%3F\"><h3>Is it safe to delete orphan files?<\/h3><\/dt>\n<dd><p>Review the list before deletion. Some files may still be used by themes or plugins that reference them directly by URL. Always back up your uploads folder first.<\/p><\/dd>\n<dt id=\"can%20i%20recover%20deleted%20files%3F\"><h3>Can I recover deleted files?<\/h3><\/dt>\n<dd><p>No, deletion is permanent. Back up your site first.<\/p><\/dd>\n<dt id=\"interaction%20with%20other%20plugins\"><h3>Interaction with other plugins<\/h3><\/dt>\n<dd><p>Some hosting providers and image optimisation plugins (such as Imagify or ShortPixel) auto-generate <code>.webp<\/code> versions of images using Nginx\/Apache rewrite rules and store them in the uploads folder without registering them in WordPress.<\/p>\n\n<p>Server-side rewrite rules is not part of the official WordPress media management specification and is not endorsed by WordPress. This plugin follows the WordPress standard \u2014 if a file is not registered in the WordPress database, it is an orphan. Any files created outside of that standard by third-party tools or hosting configurations are beyond the scope and responsibility of this plugin.<\/p>\n\n<p>If you see unexpected files in the scan results, do not select them for deletion unless you are absolutely sure they are not used.<\/p>\n\n<p>For image optimisation, the workaround is to disable server-side rewriting plugins and switch to a WordPress-native WebP converter (such as <a href=\"https:\/\/wordpress.org\/plugins\/manly-webp-converter\/\">Manly WebP Converter<\/a>) which significantly reduces file sizes and registers converted files properly in the database \u2014 after which those files will never appear as orphans.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>1.8.1<\/h4>\n\n<ul>\n<li>Added FAQ entry explaining interaction with server-side WebP rewriting plugins<\/li>\n<\/ul>\n\n<h4>1.8.0<\/h4>\n\n<ul>\n<li>Simplified plugin to focus on orphan files only<\/li>\n<li>Removed unattached images feature (use WordPress built-in Media Library filter instead)<\/li>\n<li>Expanded file format support: images, documents, audio, video, archives<\/li>\n<li>Cleaner, more focused user interface<\/li>\n<\/ul>\n\n<h4>1.7.2<\/h4>\n\n<ul>\n<li>Minor GUI fix<\/li>\n<\/ul>\n\n<h4>1.7.1<\/h4>\n\n<ul>\n<li>Removed broken automated batch deletion button<\/li>\n<\/ul>\n\n<h4>1.7.0<\/h4>\n\n<ul>\n<li>Full PHPCS\/WPCS coding standards compliance<\/li>\n<li>Performance optimization for orphan file scanning<\/li>\n<li>Security improvements with capability checks<\/li>\n<\/ul>\n\n<h4>1.6.0<\/h4>\n\n<ul>\n<li>WordPress.org compliance improvements<\/li>\n<li>Enhanced security and caching<\/li>\n<\/ul>\n\n<h4>1.5.0<\/h4>\n\n<ul>\n<li>Added orphan files detection<\/li>\n<li>Batch processing with progress tracking<\/li>\n<\/ul>\n\n<h4>1.0.0<\/h4>\n\n<ul>\n<li>Initial release<\/li>\n<\/ul>","raw_excerpt":"Finds and deletes orphan media files from the uploads directory that are not registered in WordPress.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/248642","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=248642"}],"author":[{"embeddable":true,"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/dimitriaus"}],"wp:attachment":[{"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=248642"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=248642"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=248642"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=248642"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=248642"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/de-ch.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=248642"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}