WordPress GuideErrors → Media Files Went Blank

Solved: WordPress media files went blank

woman finds best cloud vps providers

If your WordPress Media Library is suddenly showing blank thumbnails—or no images at all—you’re not alone. This common issue can stop you from uploading or displaying media across your entire site.

Let’s fix that. Below is a detailed guide with every tested solution for getting your images back—starting with the most likely causes.

Why media files in WordPress go blank

When your media files go missing or appear blank, the actual image files are usually still on the server. But something is preventing WordPress from displaying them properly in the dashboard or on your live site.

Some of the most common causes include:

You may only need to try one or two fixes—or go down the list to solve the problem. Here’s what to do.

1. Check and fix file permissions

WordPress needs permission to read, write, and display your media files. If your folder or file permissions are wrong, the Media Library can go blank.

Incorrect permissions may have been caused by a server change, plugin misbehavior, or manual file upload.

2. Deactivate plugins to find conflicts

Plugins often modify how WordPress handles media files. A plugin conflict—especially from a performance, lazy load, or security plugin—can cause your Media Library to stop displaying images.

How to test and fix it

If you can’t access your admin dashboard:

3. Switch to a default WordPress theme

Your active theme may override media display behavior, especially if it uses custom image sizes or outdated functions.

How to switch themes for testing:

If your images appear, your theme is causing the issue. You may need to update it or contact the theme developer for help.

You can switch back after confirming the issue, but don’t ignore the root problem if the theme is at fault.

4. Clear your browser and WordPress cache

Caches store versions of your site to make it load faster. But when media paths or file permissions change, cached versions can prevent new images from showing up.

Clear your browser cache

Clear your WordPress cache

If you use a caching plugin:

Also clear your hosting cache if your provider has one.

5. Disable lazy loading temporarily

Lazy loading delays image loading until the user scrolls to them. Some plugins or themes apply lazy load to admin areas, which can break image previews in the Media Library.

How to test lazy loading

Disable with code (optional)

You can disable lazy loading sitewide with this snippet in your theme’s functions.php file:

add_filter(‘wp_lazy_loading_enabled’, ‘__return_false’);

Only do this for testing. Don’t leave it disabled long term unless it’s the confirmed cause.

6. Regenerate thumbnails

If WordPress can’t find or render the correct image sizes, your media files may show as blank even if the original is fine.

How to fix with a plugin:

This forces WordPress to rebuild all registered image sizes, including the preview sizes used in the Media Library.

7. Check your .htaccess file and hotlink settings

Your .htaccess file controls many rules for your site. If it includes incorrect rewrite rules or hotlink protection, images might get blocked from showing—even to you.

How to reset your .htaccess file

Save the file and refresh your Media Library.

8. Increase your PHP memory limit

If your server doesn’t have enough memory to process images, the Media Library may silently fail to load them.

How to raise the limit

If that doesn’t work, contact your host and ask them to increase the PHP memory limit on your behalf.

9. Contact your hosting provider

If you’ve tried everything and your images are still blank, it’s time to bring in your hosting support team.

What to ask:

A good host can also scan logs, test server performance, or help roll back recent changes.

10. (Bonus) Check for mixed content if using HTTPS

If your site runs over HTTPS but media files try to load over HTTP, browsers will block them for security reasons. This is called a mixed content error.

How to fix it:

You can also update your database manually using Better Search Replace to change old http://yourdomain.com URLs to https://yourdomain.com.

Additional resources

Diagnosing WordPress errors on your site →

Even more common errors, how to troubleshoot them, and how to solve them

Fixed: WordPress failed to write file to disk →

Learn how to fix the “Upload: Failed to Write File to Disk” error in WordPress with easy troubleshooting steps.

What is managed WordPress hosting? →

What it means, what it includes, and how to decide if it’s right for you