Home » WordPress Media Library Not Showing Images

WordPress Media Library Not Showing Images

Last updated on May 25, 2021 by

Sometimes, we faced weird issues after migrating a site from one hosting to another. We have faced the WordPress media library not showing images issue after migrating a site from Siteground hosting to the Hostiner hosting.

In this article, we will share how we had fixed the WordPress media blank thumbnail issue. Let’s just jump into it.

WordPress Media Library Not Showing Images

There are possibly the following reasons that cause blank thumbnails in the WordPress media library.

  1. Security plugins adding htaccess rules that might be causing the WordPress media library not showing a thumbnail issue
  2. Not appropriate uploads folder permission
  3. After migrating a site, URL replace went the wrong issue
  4. If you had added custom htaccess rules then it might be causing the WordPress media library not showing a thumbnail issue

In our case we had added the custom htaccess rules to secure our WordPress and due to that media library not showing the images

Solution: WordPress Media Not Showing Images

01 Deactivate Security Plugin

Follow this step only if you are using a security plugin. Temporary deactivate the security plugin and check the media library.

If this step has solved your issue then you need to check which setting causes the issue and disable that setting.

02 Set Uploads Folder Permission

If the above step does not solve your problem then you need to set appropriate permission to the uploads folder.

To do that login to your hosting account, go to the File Manager -> public_html -> wp-content -> uploads and right-click on it and choose the Permissions option.

set folder permissions in wordpress

Now, set recursive folder permission to 755 as shown below, recursive will also set the 755 permissions to the subfolders and files.

set appropriate folder permissions in wordpress

Then go to the media library and check the issue is solved or not.

03 URL Replace Went Wrong

Sometimes, while migrating a site we unknowingly made mistake while replacing the site URL. Use Better Search Replace plugin to check the different URLs and then you can replace wrong URL to the correct one.

If you are a developer then you can search directly in phpmyadmin from your hosting cPanel. After correcting the URL, go to the media library and check the issue is solved or not.

04 Custom htaccess rules

We had the issue due to this point. We had added the different htaccess rules to build the security layer for our site but after lots of research, we found that some htaccess rules cause the blank thumbnail issue in the media library.

To verify that whether your htaccess causes or not, you can first copy your htaccess file to a safe place and remove all the htaccess rules and add only default WordPress htaccess rules as below:

# BEGIN WordPress

RewriteEngine On
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

# END WordPress

After that you can check the media library and we hope your issue has been resolved.

Additionally, read our guide:

  1. How To Add Back Button In Elementor
  2. 403 Error When Updating In Elementor
  3. How To Add Multiple Post Types In Posts Widget In Elementor
  4. How to Add Products Per Page Dropdown in WooCommerce
  5. “Sorry, your session has expired. Return to homepage” – WordPress WooCommerce Error
  6. How to Create a Plugin in WordPress from Scratch
  7. How to Disable Admin Bar in WordPress Without Plugin
  8. How To Send Custom Emails in WordPress
  9. How to Allow Preview of Draft Post Without Login in WordPress
  10. Import Users From CSV In WordPress Programmatically
  11. Dynamically Populate A Select Field’s Choices In ACF
  12. How To Remove WooCommerce Data After Uninstall

We hope this article helped you to resolve the WordPress media library not showing images issue.

Please let us know in the comments if everything worked as expected, your issues, or any questions. If you think this article saved your time & money, please do comment, share, like & subscribe. Thank you in advance 🙂. Keep Smiling! Happy Coding!


Leave a Comment