If you’re seeing this confusing WordPress error when trying to upload the theme, it means the process breaks at some point and that’s most probably due to a few server settings limiting resources for your site. For example the maximum upload size could be set to 5MB and the theme’s package is larger than that.
This isn’t a bug but a matter of server settings.
How to increase the Server Memory Limit?
There’s a certain amount of memory that the server will attribute to each site which it hosts. The default memory limit for WordPress is usually 32MB but processes such as importing the demo content and many other processes themes and plugins go through may require more memory. Increasing it will help you avoid some of the most common site errors.
(Beginner) Ask your hosting company to increase the memory limit
The easiest way is to reach out to your hosting company and ask theme to increase the PHP memory allocated to your WordPress site to 256M.
(Advanced) Update the values manually in the wp-config.php file
Connect to your server via FTP Find and edit the wp-config.php file in WordPress and add the following line:
Read more about increasing the PHP memory in the WordPress Codex.
Recommended PHP configuration:
- max_execution_time: 60
- memory_limit: 128M
- post_max_size: 32M
- upload_max_filesize: 32M