Local file removal
Remove local files deletes the server copy of each file after it has been uploaded to your bucket, so your media takes no disk space on the server. Your bucket then holds the only copy.
How it works#
- The main file, every image size and the original image (when WordPress kept one) are uploaded first. Local copies are deleted only after that.
- If the main file fails to upload, nothing is deleted. A size that fails to upload keeps its local copy.
- It applies to new uploads, bulk offloads, Retry all and
wp wpmc offload. - Files offloaded before the setting was turned on keep their local copies. To remove those, use Remove local copies.
- Protected store files (WooCommerce
woocommerce_uploads, Easy Digital Downloadsedd) are only offloaded, and so only removed locally, when secure downloads are on and your storage can keep them private. - Font files (
.woff2,.woff,.ttf,.otf,.eot) always keep their local copy. With Serve fonts from your site on (the default), they are not offloaded at all. See Serve fonts from your site.
Turning it on#

- Check that offloading works: upload a test image and confirm its File URL in the Media Library shows your CDN address.
- Back up your
wp-content/uploadsfolder. - Go to Media Cloud > Settings, switch on Remove local files in the Offload Behaviour card, and click Save Settings.
- Remove the local copies of media you already offloaded: go to Settings > Remove Local Copies, or run
wp wpmc remove-local. Each file is confirmed in the bucket before its local copy is deleted.

Risks#
- Deactivating or deleting the plugin: WordPress goes back to local addresses for files that are no longer on the server, and they return 404 errors. Restore the files first (see below).
- Deleting from the bucket: with no local copy, a file deleted from the bucket, with Delete from cloud when deleted in WP or in your provider’s dashboard, is gone for good.
- Server backups: they no longer include your media. Back up the bucket separately, for example with your provider’s versioning or replication.
- Local-file tools: the image editor, thumbnail regeneration and image optimizers need the original file. With Download on demand on (the default), it is fetched from your bucket automatically when they ask for it. See Download on demand.
- Staging sites: a staging copy of the site has no local media and reads from the production bucket. Give staging its own bucket, and keep mirror deletion off there.
- Large files: video and other large files are slow to download again. On media-heavy sites, consider keeping local copies.
Deleting an attachment with mirror deletion off leaves the cloud copy in your bucket. Clean up deleted media removes those leftovers later.
Restoring files to your server#
- Turn off Remove local files and save.
- On the Dashboard, in the Bulk Offload card, click Download All to Server and keep the tab open until it reports Restore complete.
- For large libraries or multisite, run
wp wpmc restoreinstead (--networkfor every site, or--sites=2,5).
Files already on the server are skipped, and the cloud copies stay in the bucket.
To restore only some items, select them in Media > Library (list view) and use the Download to server bulk action. See Media Library bulk actions.
Before deactivating the plugin#
- Turn off Remove local files and save.
- Restore your files to the server (see above).
- If you used the URL Replace tool to write CDN URLs into your database, switch them back: in Media Cloud > Migration > URL Replace, choose CDN URLs back to local and run it, or click Undo on the last run. Only addresses whose local file exists are switched back, so restore your files first (step 2).
- Check a few pages, then deactivate.