Open In App

How to Fix WordPress Media Library Not Loading?

Last Updated : 19 Sep, 2024
Comments
Improve
Suggest changes
Like Article
Like
Report

On the WordPress website, there is an option for Media, where you can upload images, videos, and other files for your website. Sometimes, users can see problems where the media library does not load properly or fails to display images. As a website owner, it is very frustrating, especially when you have public problems

Approaches to fix the WordPress media library not loading:

Deactivate All Installed Plugins

In general, if you are using the free plugin, in most cases, it is not codded in good, authentic way. If the media library of the WordPress site won't load or hangs indefinitely, plugins can be the cause of other plugins or WordPress core updates.

Steps to Deactivate All Installed Plugins

Step 1: First, open the WordPress Dashboard and then, navigate to Plugins → Installed Plugins.

Step 2: Deactivate all plugins installed in WordPress.

And, also Delete the unused Plugin.

Screenshot-from-2024-09-13-19-34-53
Click on plugin

Step 3: Check your WordPress media library to see if it's working again. If this process works, again, activate all required plugins.

Switch to a default twenty-twenty-Two theme

If you see the Media Loading Error still exists, the problem might be with your theme. Please. Switching to a default WordPress theme like TwentyTwenty-One (which is Default) can help determine if your theme is causing the problem.

Steps to Switch to a default twenty-twenty-Two theme

Step 1: Go to your WordPress dashboard.

Step 2: Navigate to Appearance > Themes.

Screenshot-from-2024-09-13-19-36-07
Navigaet to Themes

Step 3: Activate a default WordPress theme.

Screenshot-from-2024-09-13-19-36-17
Activate the default theme

If the media library starts loading correctly, so the main issue is in your theme. Kindly change the theme or, You may need to update your theme, contact the theme developer.

Clear your browser Cache and cookies

Sometimes, Huge memory amount of Browser Cache and Cookies can be the issue of not loading media Libary. Cleaning browser Cache and cookies can often solve the problem.

Steps to Clear your browser Cache and cookies

Step 1: Click the three dots in the upper right corner of the browser window.

Step 2: Select "Settings" and then "Privacy and Security".

Screenshot-from-2024-09-13-19-51-47
Navigate to the privacy and security

Step 3: Then Click on "Delete Browsing Data".

Screenshot-from-2024-09-13-19-53-31
Deleet the browsing Data

Step 4: Choose the period for which you want to clear the data.

Step 5: Select "Cookies and other site data" and "Cached images and files".

Step 6: Click on "Delete Data".

Incorrect File Permission

If you see exactly zero images, your webspace file permissions may be incorrect. This means that your WordPress doesn't have permission to open the images and, as a result, can't show them to you.

Steps to Incorrect File Permission

Step 1: Open File Manager in cPanel of your hosting.

Step 2: Navigate to the wp-content folder under public_html of your WordPress installation.

Screenshot-from-2024-09-14-08-46-04
Navigate to the wp-content

Step 3: Then Right Click on Uploads Folder and Choose Permission.

Screenshot-from-2024-09-14-08-44-30
click on permissions

Step 4: Kindly check, Permissions should be 755.

Step 5: Apply 755 permissions to the main folder and all subfolders and files (called "recursive" or "enclosed").

Screenshot-from-2024-09-14-08-47-04
apply permission

Step 6: Check your media library in the WordPress backend, is the issue solved or not.

Increase the PHP memory limit in hosting

Some hosting providers limit server resources, A PHP memory limit that is too low is another cause of problems with your media library. for not loading image media. You can edit the wp-config.php file to increase the PHP Memory limit.

Steps toIncrease the PHP memory limit in hosting

Step 1: Open the wp-config.php file in public_html in the root directory.

Screenshot-from-2024-09-14-08-48-26

Step 2: Add the following code to the file:

PHP
 define ('WP_MEMORY_LIMIT', '256M');


Screenshot-from-2024-09-14-08-52-41

Step 3: Next, Save the file and refresh your website.

Conclusion

The WordPress Media Library not loading can be caused by several factors, including plugin conflicts, theme issues, memory limits, or file permissions. By using these upper methods, which i have shown, there is almost zero chance of getting this error again, If the problem persists after trying all of these solutions, consider reaching out to your hosting provider.


Article Tags :

Explore