# Change PHP Version in FlyWP Site

Source: https://flywp.com/docs/site/configurations/php-version-change/

This guide explains how to update the PHP version and configure PHP settings for a site in FlyWP.

### Accessing PHP Settings

1. Log in to your FlyWP dashboard.
2. Go to **Sites** and select the target site.
3. In the left sidebar under **Configurations**, click **PHP**.

   ![Site sidebar with Configurations expanded and the PHP item highlighted](https://flywp.com/wp-content/uploads/2026/11/nav-site-a-2-php.png)

### Available PHP Versions & Changing Versions

The available PHP versions depend on your site's web server:

- **Nginx sites**: PHP 7.4, and 8.0 through 8.5 (7.4, 8.0, 8.1, 8.2, 8.3, 8.4, 8.5).
- **OpenLiteSpeed (OLS) sites**: PHP 7.4, and 8.1 through 8.4 (7.4, 8.1, 8.2, 8.3, 8.4).

To switch versions:

1. Locate the **PHP Version** dropdown.

   ![PHP Settings page with the PHP Version dropdown highlighted](https://flywp.com/wp-content/uploads/2026/11/nav-site-a-2-php-version.png)

2. Select your desired version.
3. Click **Save Changes**.

FlyWP will automatically reconfigure PHP-FPM for the selected version.

### Additional PHP Configuration Settings

The **PHP** configuration page also allows you to tune performance and runtime values directly from the dashboard:

- **Memory Limit**: Maximum memory allocated to each PHP script (e.g., 256M, 512M).
- **Max Execution Time**: Maximum duration in seconds a script is allowed to execute.
- **Max File Upload**: Maximum number of files that can be uploaded at once.
- **Max File Upload Size**: Maximum size of a single uploaded file (`upload_max_filesize`).
- **Max Input Time & Max Input Vars**: Maximum time spent parsing request data and maximum number of input variables accepted.
- **Process Manager**: Configure PHP-FPM pool settings (process manager mode, max children, start servers, and spare servers).
- **OPCache & JIT**: Enable or disable PHP OPCache for pre-compiled script caching, and the JIT (Just-In-Time) compiler. JIT is shown for Nginx sites on PHP 8.0 or newer, including 8.3, 8.4 and 8.5, and needs OPCache on. New sites start with JIT off; a site with no saved JIT value shows it on. If the site returns 502 errors after you turn JIT on, turn it off and save.

Click **Save Changes** to apply your adjustments.

### Outdated PHP Versions

PHP 7.4, 8.0 and 8.1 are end-of-life (EOL). They no longer get security fixes. FlyWP labels them **Outdated & Vulnerable - EOL** wherever you pick a PHP version:

- **Create Site:** the **PHP Version** list shows the label, and a security warning appears under the list.
- **PHP Settings:** the same label, and a **Security Warning** notice under the **PHP Version** field.
- **Sites list:** a warning icon next to the PHP version. Hover over the icon to read the message.
- **Site Overview:** a **Security Warning** banner, with a **Change PHP version** link if you can update the site.

You can still choose an EOL version. FlyWP shows the warning, but it does not change the PHP version of your site. Static HTML and Node.js sites do not show this warning.

#### Upgrade Advice

- Move the site to PHP **8.3 or newer**. PHP 8.2 reaches end of life on December 31, 2026.
- Check that your plugins and themes support the new version first.
- Make the change on a staging clone, test it, and then apply it to production (see [Recommended Workflow](#recommended-workflow-production)).

### Important Considerations

#### Compatibility

- Ensure your application (e.g., WordPress, plugins, themes) supports the selected PHP version
- Upgrading to PHP 8.x can break outdated plugins

#### Performance

- Newer PHP versions (8.3/8.4/8.5) offer better performance and lower memory usage
- Recommended for production unless compatibility issues exist

#### Downgrade Risks

- Downgrading PHP may cause fatal errors if code uses newer features
- Always test before switching in production

### Recommended Workflow (Production)

1. Clone site to staging
2. Change PHP version on staging
3. Test critical functionality
4. Apply the same change to production

### Verification

After switching:

- Check site loads correctly
- Review error logs (under **Monitoring & Logs** → **Logs**)
- Verify WP Admin access
- Monitor performance

### Troubleshooting

- **White screen / 500 error** → check PHP error logs
- **Plugin errors** → disable incompatible plugins
- **Composer apps** → run dependency updates if needed

### Best Practice

- Use PHP **8.3 or newer** unless you have legacy constraints, and test on staging first when moving to a newer release
- Keep PHP version aligned with your stack and framework requirements
- Periodically review and upgrade
