I'm moving a 6+ years running WordPress site to a new (Azure VM / LEMP) server, taking the time to upgrade Ubuntu, Nginx, etc, and trying to clean up years worth of grunge. ~20 authors, 40k posts, 6+GB of images, etc. I'm moving things over manually, copying the uploads folder over, so the images aren't registered in the Media Library. I'm looking at some plugins to help, but am wondering if it's necessary to re-register all the old images into the Media Library? They're all properly linked in the posts, etc. So, wondering what kind of performance gains, if any, I would get from just not bringing (most of) the images back into the Media Library? Most of these will never be used again (the ones that will I will def get into the ML). Is it worth the bother?

1 Answer 1


Assuming your old site is still accessible, I would just go Tools -> Export and create an export file containing your media.

In the new WordPress server, import the file and select the option to "Download and import file attachments". (your old site needs to be public for this to work).

This seems to be good guidance: https://www.itjon.com/moving-posts-and-media-between-wordpress-blogs-with-wordpress-importexport/

If you just copy the uploads folder, WordPress knows nothing about this and all your image references will be 404. Even if you import the media by dragging everything from your uploads folder from old site, they will have different IDs, so I would advice to follow the import method.

Once you have done this, you might want to use a plugin to find stale images and remove them. There probably is a performance gain from getting rid of image references that are somewhere in the database.

  • 1
    Thanks, this is helpful (especially the part in the linked post about exporting / importing media first. I've tried to limit the size of the export files by moving over the /uploads folder manually, but have lost Featured Images in the process. I'll try again. Luckily I have full access to both old and new servers (on separate Azure VMs), so learning to tweak PHP / Nginx settings etc to allow for export/ import of large files. Will give this plan a shot Commented Jan 4, 2021 at 14:29
  • Best of luck with this! I would recommend using "Updraft Plus" to recreate both environments on your local machine to carry out the process through various trial and errors. Once you have nailed it, you can export the optimized site to production.
    – csaborio
    Commented Jan 6, 2021 at 0:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.