PHP Version, Memory and Upload Size: Settings Worth Checking
Check which PHP version your site runs and raise the memory and upload limits that cause the most common WordPress errors.
// Good starting values PHP version: 8.3 memory_limit: 256M upload_max_filesize: 64M post_max_size: 64M max_execution_time: 120
🧰 What you need first
- Access to your control panel
- A recent backup
🎯 What you'll learn
- Find and change your PHP version
- Raise memory and upload limits
- Check your settings from inside WordPress
🛠 Tools needed
- Your hosting control panel
- WordPress Site Health (optional)
Why these settings matter
Most websites, including WordPress, run on PHP. Your host lets you choose the PHP version and set a few limits. Outdated versions are slower and stop getting security fixes, and low limits cause errors like "Allowed memory size exhausted" or "The uploaded file exceeds the upload_max_filesize".
Check what you have
In WordPress, go to Tools → Site Health → Info → Server. You'll see the PHP version, memory limit, upload size and more.
Change the PHP version
- In cPanel, search for PHP. You'll find MultiPHP Manager, Select PHP Version, or both.
- Pick a currently supported version such as 8.3.
- Reload your site and click around to check that everything works.
Note: On hosts with CloudLinux, Select PHP Version overrides MultiPHP Manager. If a change doesn't stick, use Select PHP Version.
Warning: Very old themes or plugins may break on a newer PHP version. Take a backup first, or test on a staging site.
Raise the limits
- Open Select PHP Version → Options or MultiPHP INI Editor.
- Set the values below, then save.
memory_limit 256M # room for WordPress to work
upload_max_filesize 64M # biggest single upload
post_max_size 64M # must be ≥ upload size
max_execution_time 120 # seconds before a script stops
Tip: Turn on useful extensions while you're there, like opcache (speed), imagick or gd (images) and intl.
Common problems
My change doesn't show in Site Health
Why: You changed the wrong PHP tool, or the page is cached.
Fix: Use Select PHP Version on CloudLinux hosts, then reload Site Health.
The site broke after switching PHP
Why: A theme or plugin isn't compatible with the new version.
Fix: Switch back, update the theme and plugins, then try again.
Uploads still fail
Why: post_max_size is smaller than upload_max_filesize, or WordPress has its own limit.
Fix: Set post_max_size equal to or bigger than upload_max_filesize.
Key takeaways
Keep going
- Fix errors after a change: Your Host's File Manager
- Test risky changes first: Staging Sites
Enjoyed this guide?
Support free learning at mC0de.
