DriversRecommendedOutdated drivers can make a good PC feel brokenScan driver issues before chasing fixes manually.Scan NowHalloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsWindows FixRecommendedWindows errors stealing your time? Find the fix fastScan stability, cleanup and performance issues.Fix Now×
Skip to content
VGSources
Blog

How to Change a PHP Setting on Your WordPress Hosting (cPanel, Plesk, and File Methods)

Use your hosting panel first: cPanel’s MultiPHP INI Editor or Plesk’s PHP Settings page. Learn which PHP directives control memory, uploads, POST data, and timeouts, how to keep limits consistent, and what to do when WordPress constants cannot override a server cap.
Length9 min Posted Quest giverVGSources Team

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The safest way to change a PHP setting is in your hosting control panel. In cPanel, open Software → MultiPHP INI Editor, select the domain, edit the directive, and click Apply. In Plesk, open the domain’s PHP Settings page and save the change. If your host exposes neither tool, use only the file-based method it permits—usually a domain-level php.ini, selected .htaccess directives, or WordPress constants in wp-config.php—or ask support to change the server-level value.

Before editing anything, identify the active PHP version, the exact domain running WordPress, and the setting connected to the symptom. A larger upload, for example, normally requires coordinated changes to upload_max_filesize, post_max_size, and sometimes memory_limit; changing an unrelated value or only one of those limits will not solve the error.

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

What you need to identify first

PHP settings are applied to a particular PHP configuration scope. The same domain can use a different configuration after a PHP-version change, and some hosts keep separate settings for each site or subscription. Gather these details before making an edit:

  • Domain: confirm the exact domain and document root containing the WordPress installation.
  • Active PHP version: check the hosting panel and WordPress Site Health. Do not edit a configuration belonging to an older version.
  • Symptom and directive: match the error to the setting that controls it instead of raising every limit.
  • Access level: determine whether you have a per-domain PHP editor, file access, or only support access.

Changing the PHP version can select a different configuration scope. If your host requires settings to be repeated per version, reapply them after switching versions and verify the effective values again.

Change a setting in cPanel

Open the domain editor

  1. Sign in to cPanel for the account that hosts the site.
  2. Open Software → MultiPHP INI Editor.
  3. Select the WordPress domain from the domain list. If the installation is in a subdirectory, select the domain whose document root contains that installation.
  4. Use Basic Mode for common directives or Editor Mode when you need options that are not shown in the basic form.

The hosting provider can disable MultiPHP INI Editor. If the feature or a directive is missing, that is a hosting-policy limitation rather than a WordPress error.

Edit only the directive you need

Find the directive associated with the failure, enter a value with an appropriate unit such as M for megabytes or s for seconds, and leave unrelated settings unchanged. cPanel’s documented workflow is to make the adjustment—for example, to memory_limit—and click Apply at the bottom of the page.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  1. Enter the new value in the field or editor.
  2. Review the other related limits before saving.
  3. Click Apply.
  4. Wait for the panel to confirm the change, then verify the effective value in WordPress Site Health or a host diagnostic.

Deleting the domain-level or home-directory php.ini can reset settings to the host’s defaults. Do not remove that file as a troubleshooting shortcut unless you have recorded the existing values and understand the reset.

Change a setting in Plesk

  1. Sign in to Plesk.
  2. Open Websites & Domains and select the WordPress domain.
  3. Open the domain’s PHP Settings page. The exact label can vary by Plesk configuration and hosting provider.
  4. Locate the directive, enter the required value, and save or apply the page.
  5. Recheck the value from WordPress Site Health, then repeat the operation that failed.

Plesk may expose only the directives and maximum values allowed by the provider. A field that is locked, absent, or rejected indicates that the host must make the change at a higher configuration level.

Use a file-based method when the panel is unavailable

Hosts differ in which override files they permit. WordPress documentation identifies a domain-level php.ini, permitted .htaccess directives, and constants in wp-config.php as possible routes, but a host can disable any of them. Check the host’s own instructions before adding a file or directive.

Domain-level php.ini

If the host supports it, create or edit the php.ini in the domain’s document root. An illustrative set of directives looks like this:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
memory_limit = 256M
upload_max_filesize = 64M
post_max_size = 80M
max_execution_time = 300
max_input_time = 300

These values are examples of syntax, not a promise that your account permits them. Replace them with values appropriate to the task and the limits stated by your provider. Some hosts require the file in a particular directory or require PHP-FPM, a service reload, or a delay before the new values become active.

.htaccess overrides

Apache-based accounts sometimes allow PHP directives in .htaccess, while other configurations reject them. A permitted syntax can look like:

php_value memory_limit 256M
php_value upload_max_filesize 64M
php_value post_max_size 80M

Use this only when your host explicitly supports PHP values in .htaccess. On a server that disallows them, the result can be an HTTP 500 error rather than a changed limit. If that happens, remove the added lines through the file manager or SFTP, restore the site, and ask the host which method is supported.

WordPress constants in wp-config.php

WordPress can request memory for its front end and administration area through constants placed in wp-config.php, before the line that says WordPress editing should stop. For example:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
define('WP_MEMORY_LIMIT', '256M');
define('WP_MAX_MEMORY_LIMIT', '256M');

WP_MEMORY_LIMIT controls the amount of memory WordPress requests for front-end rendering. WordPress documentation gives a default of 40 MB for a standard installation and 64 MB for Multisite. WP_MAX_MEMORY_LIMIT controls the back end and has a documented default of 256 MB.

These constants are requests made by WordPress; they do not override a lower server-level memory_limit. If the PHP configuration prevents runtime changes, adding a larger constant will not increase the amount PHP can allocate. A host must raise the server limit when the account’s ceiling is lower.

Which PHP setting controls which problem?

Directive or constant What it controls Important relationship or qualification
memory_limit Maximum memory PHP may allocate for one request. PHP can refuse a higher WordPress request when the server configuration imposes a lower ceiling.
WP_MEMORY_LIMIT Memory WordPress requests while rendering the front end. WordPress documents defaults of 40 MB for standard installs and 64 MB for Multisite.
WP_MAX_MEMORY_LIMIT Memory WordPress requests for administration tasks. WordPress documents a default of 256 MB.
upload_max_filesize Maximum size of one uploaded file. This is the limit named in “uploaded file exceeds the upload_max_filesize directive in php.ini” errors.
post_max_size Maximum size of the complete HTTP POST request. It must be at least as large as upload_max_filesize.
max_execution_time Maximum time a PHP script may execute. Raise it only when a genuinely long-running request times out.
max_input_time Time PHP allows for receiving input. It is distinct from execution time and can affect large uploads.

Fix the “uploaded file exceeds upload_max_filesize” error

Changing only upload_max_filesize often leaves the upload blocked by another limit. Keep the limits internally consistent:

memory_limit ≥ post_max_size ≥ upload_max_filesize

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  1. Open the active domain in cPanel’s MultiPHP INI Editor or Plesk’s PHP Settings page.
  2. Set upload_max_filesize above the size of the individual file you need to upload.
  3. Set post_max_size at least as high as the upload limit, leaving room for the rest of the HTTP request.
  4. Check memory_limit. Large imports, image processing, and archive extraction may need more memory than the upload itself.
  5. Check max_input_time if the connection spends a long time sending the file.
  6. Save the settings, verify the effective values, and retry the upload.

A cPanel upload guide reports a default maximum upload size of 2 MB for cPanel and describes values up to 2 GB in that procedure. Those figures describe that documented cPanel procedure; your provider can impose lower account-level caps.

Increase the WordPress memory limit safely

Memory errors can occur during plugin updates, theme operations, media processing, backups, or imports. First determine whether the failure is front end, administration, or a PHP process outside WordPress.

When the WordPress constant is enough

If the server’s memory_limit is already high enough and the application is requesting less, adding or adjusting WP_MEMORY_LIMIT or WP_MAX_MEMORY_LIMIT may let WordPress request more memory. Keep the constants in wp-config.php and verify the result in Site Health.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

When the host must change it

If Site Health continues to show a lower PHP memory limit, or the constant has no effect, the server configuration is enforcing the ceiling. Shared hosting commonly applies server-level caps. Contact the provider and include the domain, active PHP version, current effective value, requested value, and the operation that fails.

Verify the effective value instead of trusting the file

A saved file or green confirmation in a panel does not prove that the running PHP process uses the value you entered. Check WordPress’s Site Health information or a diagnostic supplied by your host. Confirm the exact values for:

  • memory_limit
  • upload_max_filesize
  • post_max_size
  • max_execution_time
  • max_input_time

Then repeat the failed operation with a test file or task that stays within the new limits. Remove temporary diagnostic files after checking them, particularly if they reveal server details.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Troubleshoot a change that did not work

The setting reverted after saving

The provider may enforce a maximum, regenerate configuration files, or require edits in a different scope. Confirm the active PHP version and domain, then ask support whether the account uses a separate PHP-FPM pool or server-level policy.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
Teacher Record Book
  • Keep track of everything from attendance to test scores
  • Spiral bound
  • Measures 8-1/2" x 11"

The panel has no editor

MultiPHP INI Editor can be disabled by the provider. Look for the host’s documented php.ini location or permitted .htaccess method. If neither is available, support must make the change.

WordPress still reports the old value

Recheck the domain and PHP version, then verify the file’s location and syntax. A directive in the wrong document root can affect another site or no site at all. PHP-FPM or another persistent process may also need the provider to reload its configuration.

The site returns HTTP 500 after an .htaccess edit

Undo the newly added php_value lines immediately. The server likely disallows those overrides. Restore the previous file, confirm the site loads, and use the panel, a supported php.ini, or hosting support instead.

The upload limit increased but the upload still fails

Compare all three values: upload_max_filesize, post_max_size, and memory_limit. Also check max_input_time for slow transfers and application-specific limits imposed by the plugin handling the upload.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

A long task times out

Only after confirming that the task is legitimate and necessary should you examine max_execution_time. For a large upload, distinguish the time spent receiving input—controlled by max_input_time—from the time spent processing it. Raising execution time cannot fix a smaller upload-size limit.

Questions to ask before choosing or changing hosting

If PHP settings are a recurring requirement for a WordPress site, compare hosting plans using concrete controls rather than a generic promise of flexibility:

  • Does the account expose a per-domain PHP editor?
  • Can you select the PHP version for each domain?
  • What maximum values are allowed for memory, uploads, POST data, and execution time?
  • Are domain-level php.ini or .htaccess overrides permitted?
  • Does changing a value require a PHP-FPM or server restart?
  • How does support handle requests above shared-host caps?

Ask for the current limits and the exact control-panel path in writing. A host that exposes the editor but silently caps values still requires support for larger applications or imports.

Quick Recap

SaleBestseller No. 1
SaleBestseller No. 3
Bestseller No. 4
Teacher Record Book
Teacher Record Book
Keep track of everything from attendance to test scores; Spiral bound; Measures 8-1/2" x 11"
$4.89

A safe change checklist

  1. Record the current effective values.
  2. Identify the active PHP version and WordPress domain.
  3. Choose the smallest directive change that addresses the symptom.
  4. Keep memory_limit ≥ post_max_size ≥ upload_max_filesize for upload work.
  5. Save through the hosting panel whenever possible.
  6. If using files, make a backup and use only methods the host permits.
  7. Verify the running PHP values in Site Health or a host diagnostic.
  8. Retry the failed operation and remove temporary diagnostic files.
  9. Contact support when the value is locked, capped, or unchanged after verification.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More quests from Patch Notes

  1. How to Set Up a RedM (RDR2) Server in 2026: License Key, txAdmin and server.cfg, Step by StepBlog11min
  2. Best RedM (RDR2) Server Hosting in 2026: Comparing Four Hosts on Slots, Memory and PriceBlog10min
  3. How to Host a Mindustry Server in 2026: server-release.jar, Port 6567 and the Commands That MatterBlog7min
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.