What is Enable Media Replace plugin?
Enable Media Replace is a free WordPress plugin that adds a “Replace Media” feature to the WordPress media library — allowing administrators to replace an existing media file with a new version while keeping the same file attachment ID, URL, and all existing references throughout WordPress. Without this plugin, updating an image requires: deleting the old attachment (breaking all references), uploading the new file (receiving a new ID and URL), and manually updating every post, page, widget, and custom field that referenced the old file. Enable Media Replace eliminates this process with a single “Upload New Version” action.
The plugin adds a “Replace Media” link in the media library edit screen. Clicking it reveals a file upload form with two replacement options: (1) replace with same file name (preserving the exact URL), or (2) replace and use new file name (updating references automatically). After replacement, WordPress regenerates thumbnails for the new file in all registered image sizes. The attachment ID, alt text, caption, and description remain unchanged — only the file itself is replaced.
Enable Media Replace is completely free and one of the most universally useful WordPress utility plugins. It is particularly valuable for WooCommerce product images, site logos, and featured images that need periodic updates without breaking existing references. With 1 million+ active installations and a 4.9-star rating, it is the standard solution for image replacement in WordPress.
Need Help With Enable Media Replace Setup, Troubleshooting, or Customization?
Need help with Enable Media Replace? Whether you are dealing with errors, broken functionality, styling problems, plugin conflicts, or advanced customization, we can help you fix the issue and get the plugin working properly on your WordPress site.
Get Enable Media Replace Expert HelpKey Features
- Replace existing media files without changing the attachment ID or URL
- Choose to keep same filename (exact URL preserved) or use new filename (references auto-updated)
- Automatic thumbnail regeneration for all image sizes after replacement
- Image metadata (alt text, caption, description) preserved
- Works with all file types: images, PDFs, videos, documents
Pros & Cons
Pros
- Solves a genuine WordPress limitation — image replacement without breaking references
- 1 million+ installations with 4.9-star rating demonstrates exceptional reliability
- Thumbnail regeneration after replacement ensures correct sizes throughout the site
Cons
- CDN-cached URLs for the old file version require CDN cache purge after replacement
- Offload Media setups may require additional configuration for proper replacement
Free vs Premium
Completely free. No paid version.
Common Problems & Fixes
After replacing a media file with Enable Media Replace, the old image still shows on the site. How do I clear the cached version?
Old image display after replacement is typically a caching issue: (1) clear WordPress page cache (WP Rocket, LiteSpeed Cache, W3TC — whatever is installed); (2) if using a CDN (Cloudflare, BunnyCDN), purge the CDN cache for the specific image URL; (3) browser cache — hard refresh (Ctrl+Shift+R) the affected page; (4) if using an object cache (Redis), flush the object cache; (5) if using an image optimization service (Imagify, Smush), the optimized cached version may need to be cleared in the optimization plugin settings.
Enable Media Replace replaced the file but thumbnails are still the old image dimensions — the new image has different dimensions. How do I regenerate thumbnails?
Enable Media Replace automatically triggers thumbnail regeneration. If thumbnails are still old: (1) verify the replacement completed successfully (no error messages during upload); (2) for large images, the regeneration may take time — refresh the media library after a few seconds; (3) if regeneration failed (PHP memory limit or timeout), run the Regenerate Thumbnails plugin manually to regenerate thumbnails for the replaced attachment; (4) clear all caches after thumbnail regeneration.
Enable Media Replace is not appearing in the media library — the "Replace Media" link is missing from the attachment edit screen. How do I access the replacement feature?
The replacement link appears in the attachment edit screen (not the media library grid view). Access it by: (1) opening the media library, clicking on a file to open its attachment details; (2) clicking “Edit more details” to open the full attachment edit screen; (3) the “Replace Media” or “Upload a new file” link appears in the Actions section of the edit screen. If the link is still missing: verify Enable Media Replace is active (WordPress → Plugins); try deactivating and reactivating the plugin.
Customization & Developer Notes
How do I replace a WooCommerce product image using Enable Media Replace?
Go to the WooCommerce product → Product Gallery section. Click the product image to open its media details. Alternatively, go to Media → Library and search for the product image. In the attachment edit screen, click “Upload a new file” (Enable Media Replace). Upload the new product image and select whether to keep the same filename (preserving the CDN URL) or use the new filename. After replacement, WordPress regenerates the product image thumbnails. The product page immediately shows the new image without any manual reference updates needed.
How do I replace a PDF document in WordPress while keeping the same download URL?
Navigate to Media → Library, find the PDF, and open its attachment edit screen. Click “Upload a new file” (Enable Media Replace). Upload the new PDF version. In the replacement options, select “Keep the same filename” — this ensures the download URL (/wp-content/uploads/year/month/document.pdf) remains exactly the same. All existing links to this PDF throughout posts, pages, and external sites continue to work and will now serve the new PDF version. Clear CDN and page caches after replacement.
Frequently Asked Questions
What happens to the old file after Enable Media Replace replaces it?
Enable Media Replace replaces the file on disk with the new version. If you keep the same filename, the old file is overwritten — it no longer exists. If you use a new filename, the old file may remain on the server in the uploads directory. Enable Media Replace does not automatically delete old thumbnail files when replacing (these accumulate over time). For cleanup, use a media cleanup plugin or the “Delete unused thumbnail sizes” feature in the Regenerate Thumbnails plugin to remove orphaned thumbnail files.
Does Enable Media Replace work with WP Offload Media (files stored on S3/CloudFront)?
Enable Media Replace has specific documentation for WP Offload Media compatibility. When replacing media on a site using WP Offload Media, the plugin must upload the new file to the local server and then the offload process pushes it to S3. The replacement may require manual offload synchronization after the local replacement. Check the Enable Media Replace and WP Offload Media documentation for the current recommended workflow, as compatibility approaches may have been updated.
Can Enable Media Replace break after updates?
Yes, that can happen, especially on older sites with many plugins. This usually happens when the plugin, theme, and add-ons are updated out of sequence. In most cases, testing on staging catches the issue before it reaches the live site. From experience, backups and changelog reviews save a lot of cleanup time.
What should I check before installing Enable Media Replace?
Start by checking whether another plugin already does the same job. In most cases, overlap is what creates avoidable conflicts and performance issues. A common issue is installing a plugin because it looks convenient without checking the stack first. From experience, a short compatibility review avoids most of the pain later.