How to Fix WordPress Plugin Installation Failed Errors

How to Fix WordPress Plugin Installation Failed Errors

The installation of the plugin using WordPress is generally easy but there could be times when installation fails because of error messages such as “installation failed”, “could not create directory”, “the package could not be installed”, or “are you sure you want to do this?” These errors will hinder you from installing any new functionality.

Sometimes, the problem is not caused by the plugin but rather some other issues like PHP upload limitations, low memory or disk space, wrong file permissions, hosting provider’s policies, or wrong plugin packages that can hinder the installation process. The WordPress hosting environment you have can also affect the ease of plugin uploads and installations.

In this guide, you will find out how to deal with common WordPress plugins installation errors by verifying PHP settings, available space, file permissions, WordPress settings, and hosting environment.

Why Does WordPress Plugin Installation Fails?

WordPress must be able to upload, extract, and write files on your site’s server. Any blockage at that stage will result in failure of installation.

Possible reasons for this problem include:

  • Too large size of plugin ZIP file
  • The plugin does not support your WordPress and PHP versions
  • Limited PHP memory
  • Disk space exhausted in your hosting account
  • Low value of upload_max_filesize
  • WordPress does not have write access to the plugin directory
  • Permissions of files and folders are wrong
  • Insufficient post_max_size
  • The plugin file is corrupt
  • There are restrictions in the hosting environment

Knowing the cause is better than trying the installation again and again.

How to Solve WordPress Plugin Installation Failed Errors

1. Verify the Plugin File and Installation Process

  • Before modifying any server settings, verify that you have the right plugin file package.
  • Ensure that the plugin ZIP file is really a plugin ZIP, not an archive containing documentation and the plugin ZIP within.
  • If the ZIP file is corrupt, download the file once more.
  • Make sure the plug-in is compatible with the version of WordPress and PHP.
  • Install the plugin by going to the plugins tab, add new plugin and then uploading the plugin.
  • If you fail to install through the dashboard, write down the error messages that come up as they may indicate upload limits or other restrictions.

If the plugin is not installed via the WordPress dashboard, it can be done manually as well. Simply unzip the plugin zip file and upload the plugin folder into wp-content/plugins/ folder in your WordPress installation using cPanel File Manager or FTP. However, for more assistance on uploading website files using cPanel File Manager, you can refer to the guide at HarmonWeb.

After uploading the files, visit Plugins > Installed Plugins on your WordPress dashboard and activate the plugin.

Should you be using HarmonWeb as the host for your WordPress site, you may as well verify the hosting environment and available resources through your hosting control panel. It will help to establish whether the problem is the plugin or the host’s restrictions.

2. Review the value of upload_max_filesize

Among the most common issues which cause the upload process of the manually uploaded plugin to be unsuccessful is the exceeding of the PHP uploading limitations by the ZIP file itself. The parameter of upload_max_filesize dictates what size of file PHP permits a user to upload.

For instance, if your server supports the uploading of files up to 2 MB in size while the plugin ZIP file is 5 MB in size, the uploading process may fail even before the installation of the plugin on WordPress.

You can find out the configuration setting for PHP by accessing the hosting control panel or Site Health section of WordPress.

For instance:

upload_max_filesize = 64M

Increase of WordPress upload limit and PHP limits is also described in HarmonWeb’s article on solving image uploading problems in WordPress.

This depends on your site’s and hosting’s configuration. There is no point in increasing the limit if it doesn’t improve WordPress performance.

3. Check post_max_size

The other PHP directive that can influence file uploading is post_max_size.

This is the maximum POST data that will be accepted by PHP.

In general, it should be at least as large as upload_max_filesize. Otherwise, increasing only the upload size limit will not help.

For instance:

upload_max_filesize = 64M

post_max_size = 64M

The variables that you can use vary according to your hosting environment.

In case you are using cPanel, it might be possible for your hosting company to give you access to edit your PHP variables via PHP configuration editor.

4. Increase PHP Memory Limit

An attempt at plugin installation can fail if there is not enough PHP memory allocated to carry out the procedure.

While a memory-related issue would not necessarily look like an ordinary upload problem, increasing the amount of PHP memory can resolve a plugin installation or unpacking problem if it needs extra resources.

If your hosting allows it, one way to do that would be via wp-config.php:

define( ‘WP_MEMORY_LIMIT’, ‘256M’ );

This is, however, not likely to override a lower PHP memory limit at the server level.

For more specific guidance, refer to the HarmonWeb instructions for how to raise the WordPress PHP memory limit. If your host sets limits on the amount of PHP memory that your account can have, then it is best to contact them for an upgrade or switch plans.

5. Ensure that There Is Sufficient Disk Space

Disk space is needed to ensure that a plugin can be uploaded and extracted. Although a plugin is compressed into a ZIP file and can be small, WordPress may still require some extra disk space to extract the files.

This could cause installation issues in case your hosting has reached maximum capacity. Make sure to check your control panel in order to determine the space which is being consumed on the server by you.

Unnecessary backups, cache files, old plugin files, unused themes, large media files, and temporary files should also be considered.

Don’t delete files because you don’t know what they are. Backup and identify the purpose of a file or folder before deleting it. In case you are constantly running out of space in your website’s storage, perhaps it would be better to upgrade your host plan.

6. Verify File and Directory Permissions

WordPress requires the right permissions to create and change files in directories like the following:

wp-content/plugins

If there is an incorrect permission, the message that WordPress will show you is:

“Installation Failed: Could Not Create Directory.”

This can happen due to website migration, transferring files manually, changing the server, or backup restoration.

When you do not know which permissions are needed for your WordPress installation, you can always ask your web host or system administrator to check file and directory ownership and permissions.

We also address permission issues in our guide on why WordPress auto-updates fail and how to fix them. Do not randomly change the permission settings as it could lead to security issues as well as installation errors.

7. Check for Plugin Conflicts and Compatibility

When you make sure that PHP, storage and permission issues are sorted out, try checking plugin compatibility.

Your plugin may be incompatible with your version of WordPress, PHP, other plugins, themes or even the server.  In case the issue occurred after activating an update of some other plugin, then it should be disabled first to see if that resolves the issue.

The process of dealing with common issues in WordPress is described in our troubleshooting guide for deactivating plugins and themes. WordPress debugging techniques can be used to detect conflicts with any plugins.

8. Try Manual Installation

In case the plugin installation through the WordPress dashboard is not successful, you may try installing it manually if you can access your web host control panel.

The steps involved are:

  • Download the plugin ZIP file for the plugin you wish to install
  • Extract it on your computer
  •  Upload it to wp-content/plugins/ in WordPress
  • Login to WordPress
  • Navigate to Plugins → Installed Plugins
  • Activate the plugin

The procedure can assist in establishing whether the issue arises from the WordPress uploading process.

In case you’re not using cPanel File Manager but FTP, there is also another tutorial provided about connecting cPanel to FileZilla.

Nevertheless, manual installation will not address any permission and storage issues. The WordPress site needs proper permissions to access the plugin files.

9. Check Hosting Environment

In case the installation process fails despite examining the plugin package and WordPress settings, the hosting environment might also be a cause of such failure. Shared hosting will work well for most WordPress sites, however, the hosting account operates in certain limitations of resources and configurations.

Websites with high traffic, WooCommerce, and sites with many plugins might at some point need more CPU, memory, storage, or more flexibility in configurations.

Learning about shared hosting will give you an insight into whether your hosting environment suits your website. WordPress hosting might be an ideal option for those who require an environment specifically geared towards WordPress.

10. Look at VPS Hosting for More Control

If you would like more control in areas such as PHP settings, server resources, file permissions, or other server-related settings, then consider using a VPS. The VPS is a much more isolated solution and offers much more control over things than the usual shared hosting.

This may be helpful in the case of bigger WordPress sites, WooCommerce store, development works, and websites that have difficult-to-manage plugins. VPS hosting demands more technical skills as well. It doesn’t have to be done just because one plugin couldn’t be installed.

In case you need more power from your hosting environment, VPS hosting can come in handy.

Quick Checklist

Before contacting support, check:

  • Is the plugin ZIP file valid?
  • Is upload_max_filesize large enough?
  • Is post_max_size big enough?
  • Is PHP memory sufficient?
  • Is the disk space available?
  • Can WordPress write into the wp-content/plugins/ directory?
  • Is your file permission set up correctly?
  • Is the plugin compatible with your WordPress and PHP versions?
  • Is there some other plugin or theme creating an issue?
  • Does your web host have sufficient server resources?

Steps to Avoid Plugin Issues

Make sure that you keep WordPress, your plugins, themes, and PHP up-to-date. However, always test for compatibility first.

This list should also include:

  • Regular site backups.
  • Removal of unused plugins.
  • Monitoring of hard drive usage.
  • Monitoring of host server resource usage.
  • Download of plugins from legitimate sources.
  • Avoiding of permission changes that you do not understand.
  • Selection of sufficient host server resources.

Conclusion

Installation problems for WordPress plugins can be caused by upload size limits, memory constraints of the PHP, lack of space on the server’s drive, permission issues, incompatibilities between the plugins or limitations imposed by the host. You should first look at the plugin files and PHP configuration.

In case these issues keep recurring, your hosting environment might not be able to provide enough resources or configuration options for your website.

Looking for Improved Hosting Solutions for Your WordPress Website?

Let your hosting solutions limitations not prevent you from installing and managing the plugins your website requires.

Select HarmonWeb WordPress Hosting for a hosting environment built specifically for WordPress with the necessary resources and support that will allow your website to thrive.

Transfer your WordPress website to HarmonWeb now and give your website the hosting environment it deserves.

Comments

No comments yet. Why don’t you start the discussion?

    Leave a Reply