How to Fix WordPress Media Library Not Loading

WordPress media library not loading spinner shown over grey placeholder images in the WordPress dashboard
The WordPress media library stuck on a loading spinner with grey placeholders instead of your images.

If wordpress media library not loading is what you see every time you open Media > Library, you are not alone. Instead of your images, you may see grey boxes, an endless spinner, or a completely blank page.

The media library loads your images with JavaScript and small background requests. When anything blocks those requests, the grid never appears. The good news is that the causes are limited and most of them are simple to fix.

This guide walks you through 7 fixes in order from the simplest to the most advanced. Work through them one by one. Most people solve the problem in the first three fixes.

Table of Contents

  • Quick Checks
  • Diagnose: Match Your Symptom
  • Fix 1: Hard Refresh When WordPress Media Library Not Loading
  • Fix 2: Check the Browser Console for JavaScript Errors
  • Fix 3: Deactivate Plugins to Find the Conflict
  • Fix 4: Switch to a Default WordPress Theme
  • Fix 5: Increase the PHP Memory Limit
  • Fix 6: Fix File and Folder Permissions
  • Fix 7: Reinstall WordPress Core Files
  • What to Avoid
  • Frequently Asked Questions
  • Conclusion

Quick Checks

Try these fast checks first. Each takes less than a minute.

  • Open the media library in a private or incognito window to rule out bad browser cache.
  • Press Ctrl + F5 on Windows or Cmd + Shift + R on Mac to hard refresh the page.
  • Try a different browser to see if the problem is browser-specific.
  • Log out of WordPress and log back in to refresh your session.
  • Check that your internet connection is stable and not dropping requests.
  • Wait one minute and reload. A busy server can delay the media grid.

If none of these help, move on to the diagnose table below.

Diagnose: Match Your Symptom

SymptomCauseGo to Fix
Grey boxes with a spinning loader that never stopsA JavaScript or background request failureFix 1, Fix 2
“No media files found” even though files exist on the serverPermission or database records issueFix 6
New uploads never appear in the library gridLow PHP memory or blocked upload requestFix 5, Fix 6
Library worked fine until a new plugin or updatePlugin or theme conflictFix 3, Fix 4
Blank white area where the image grid should beCorrupted core file or fatal PHP errorFix 7

Fix 1: Hard Refresh When WordPress Media Library Not Loading

Your browser may be loading an old cached copy of the admin scripts. A hard refresh forces it to download fresh files.

  1. Go to Media > Library in your WordPress dashboard.
  2. Press Ctrl + F5 (Windows) or Cmd + Shift + R (Mac).
  3. Wait for the page to fully reload and check the grid.
  4. If the spinner is still stuck, clear your browser cache completely:
  5. Open browser settings and find Privacy or History.
  6. Choose Clear browsing data for cached images and files.
  7. Reload the media library and check again.
  8. Try the library in a private or incognito window. If it works there, your normal browser cache was the problem.

If uploads themselves also fail with errors, read our guide on image upload failed in WordPress.

Fix 2: Check the Browser Console for JavaScript Errors

The media grid is built by JavaScript. If a script throws an error, the grid never finishes loading. The browser console shows you exactly which script broke.

  1. Open the media library page.
  2. Press F12 on Windows or Cmd + Option + J on Mac to open the developer tools.
  3. Click the Console tab at the top of the panel.
  4. Look for red error messages. These tell you what went wrong.
  5. If an error names a plugin file (for example, a path under /wp-content/plugins/), that plugin is the likely cause. Jump to Fix 3.
  6. If you see errors about blocked or failed network requests, click the Network tab, reload the page, and look for requests marked in red.
  7. Take a screenshot or copy the error text. You will need it if you contact your hosting support later.
Browser developer console showing red JavaScript errors while wordpress media library not loading
The browser console reveals red JavaScript errors that stop the media grid from loading.

Fix 3: Deactivate Plugins to Find the Conflict

Plugins are the most common cause of this problem. A single poorly coded plugin can break the admin JavaScript for the whole site.

  1. Go to Plugins > Installed Plugins in your dashboard.
  2. Select all plugins using the checkbox at the top of the list.
  3. Choose Deactivate from the bulk actions menu and click Apply.
  4. Open Media > Library and check if the grid now loads.
  5. If the library works, one of the plugins was the cause. Now find it:
  6. Reactivate your plugins one by one.
  7. Check the media library after each activation.
  8. When the library breaks again, the last plugin you activated is the culprit.
  9. Keep the faulty plugin deactivated and look for an updated version or a replacement.
WordPress plugins list with the Deactivate option selected to fix wordpress media library not loading
Deactivating all plugins at once is the fastest way to test for a plugin conflict.

Security and optimization plugins are frequent offenders because they modify scripts or block requests. For a deeper walkthrough, see our WordPress plugin conflict fix guide.

Fix 4: Switch to a Default WordPress Theme

If deactivating plugins did not help, your theme may be the problem. Themes can load their own admin scripts that clash with the media library.

  1. Go to Appearance > Themes in your dashboard.
  2. Activate a default WordPress theme such as Twenty Twenty-Four.
  3. Open Media > Library and check if the grid loads now.
  4. If it works, your old theme is causing the conflict. Contact the theme author or switch themes.
  5. If it still does not work, switch back to your normal theme and continue to Fix 5.

Fix 5: Increase the PHP Memory Limit

WordPress needs enough server memory to build image thumbnails and load the library. When memory runs out, the background requests fail silently and the grid stays empty.

First, check your current limit:

  1. Install the free Site Health information view: go to Tools > Site Health > Info and open the Server section.
  2. Look for the PHP memory limit value.
  3. If it shows 128M or less, it is likely too low for a media-heavy site.

Now raise the limit with the wp-config.php method:

  1. Open your hosting file manager or connect with an FTP client.
  2. Find the file wp-config.php in your site’s root folder.
  3. Download a backup copy to your computer first.
  4. Edit the file and add this line just above the line that says “stop editing”:
  5. define( 'WP_MEMORY_LIMIT', '256M' );
  6. Save the file and upload it back to the server.
  7. Reload the media library and check the grid.

If your host allows it, you can also raise the limit from your hosting control panel under PHP settings.

Hosting control panel PHP options showing memory limit 256M to fix wordpress media library not loading
Raising the PHP memory limit in your hosting panel gives WordPress enough room to build the media grid.

Low memory can also trigger fatal errors elsewhere in the admin. If you see white screens on other pages too, our WordPress critical error fix guide can help.

Fix 6: Fix File and Folder Permissions

WordPress must be able to read the files in your uploads folder. If server permissions are wrong, the library cannot display the images even though the files exist.

The correct values are:

  • 755 for folders
  • 644 for files
  • wp-config.php can be stricter at 440 or 400

Here is how to set them with an FTP client:

  1. Connect to your site with your FTP client.
  2. Right-click the wp-content/uploads folder and choose File permissions.
  3. Enter 755 and apply it to the folder, its subfolders, and files if your client offers that option.
  4. Then select the files inside uploads, set them to 644, and apply.
  5. Never set anything to 777. That value gives full access to everyone and is a security risk.
File manager permissions dialog set to 755 for folders and 644 for files to fix wordpress media library not loading
Setting folders to 755 and files to 644 lets WordPress read your uploads safely.

Reload the media library after changing permissions. If the grid appears, the permissions were blocking it.

Fix 7: Reinstall WordPress Core Files

If nothing else worked, a core file may be corrupted or missing. Reinstalling core files is safe. It replaces the WordPress software files but keeps your content, themes, plugins, and database untouched.

  1. Go to Dashboard > Updates in your admin panel.
  2. If an update is available, click Update now and wait for it to finish.
  3. If no update is available, click the Re-install now button under the current version.
  4. Wait for the process to complete. Do not close the page during the reinstall.
  5. Open Media > Library and check the grid.

Still stuck? If the whole admin feels slow or other pages fail to load, caching or server issues may be involved. See our guide on WordPress website not loading for server-side checks.

What to Avoid

  • Do not set file permissions to 777. It creates a serious security hole.
  • Do not install a nulled or pirated plugin hoping it fixes the issue. They often contain malware.
  • Do not edit core WordPress files directly. Reinstall them instead using Fix 7.
  • Do not raise the memory limit to an extreme value like 1024M. Ask your host what is reasonable first.
  • Do not delete the uploads folder or your image files. The problem is almost never the files themselves.
  • Do not ignore the browser console. Guessing wastes far more time than reading the actual error.

Frequently Asked Questions

Why is the wordpress media library not loading, but my site still looks fine?

The front of your site and the admin area use different scripts. A JavaScript error can break the media grid while the public pages keep working. Fix 2 shows you how to spot the error.

Can a new plugin really break the media library?

Yes. It is one of the most common causes. Plugins that add admin scripts, block requests, or change the upload folder can stop the grid from loading. Fix 3 walks you through finding the bad plugin.

How do I know if low PHP memory is the problem?

Open Tools > Site Health > Info > Server and check the PHP memory limit. If it is low and your library holds many large images, memory is a strong suspect. Fix 5 explains how to raise it.

Will reinstalling WordPress delete my images or posts?

No. Reinstalling core files only replaces the WordPress software files. Your uploads, posts, pages, themes, plugins, and database stay exactly as they are.

The library loads in one browser but not another. What does that mean?

That points to a browser cache or extension problem. Clear the cache, disable extensions, or use a private window as described in Fix 1. The issue is on your computer, not your server.

Do I need to contact my hosting provider?

Only as a last step. If all 7 fixes fail, send your host a screenshot of the console errors from Fix 2. That gives them exactly what they need to help you faster.

Conclusion

A wordpress media library not loading is frustrating, but it is almost always fixable without losing any files. Start with a hard refresh, check the console, and test for plugin conflicts. Those three steps solve the problem for most site owners.

If you needed the advanced fixes, consider what changed on your site just before the problem started. A new plugin, a theme update, or a server change is usually the trigger. Keep your plugins and themes updated from official sources, and your media library will keep loading smoothly.

Helpful Official Resources

Leave a Reply

Your email address will not be published. Required fields are marked *