Title: wp_is_php_version_acceptable
Published: March 13, 2019
Last modified: February 24, 2026

---

# apply_filters( ‘wp_is_php_version_acceptable’, bool $is_acceptable, string $version )

## In this article

 * [Description](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#description)
 * [Parameters](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#parameters)
 * [Source](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#source)
 * [Related](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#related)
 * [Changelog](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#changelog)

[ Back to top](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#wp--skip-link--target)

Filters whether the active PHP version is considered acceptable by WordPress.

## 󠀁[Description](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#description)󠁿

Returning false will trigger a PHP version warning to show up in the admin dashboard
to administrators.

This filter is only run if the wordpress.org Serve Happy API considers the PHP version
acceptable, ensuring that this filter can only make this check stricter, but not
loosen it.

## 󠀁[Parameters](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#parameters)󠁿

 `$is_acceptable`bool

Whether the PHP version is considered acceptable. Default true.

`$version`string

PHP version checked.

## 󠀁[Source](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#source)󠁿

    ```php
    $response['is_acceptable'] = (bool) apply_filters( 'wp_is_php_version_acceptable', true, $version );
    ```

[View all references](https://developer.wordpress.org/reference/files/wp-admin/includes/misc.php/)
[View on Trac](https://core.trac.wordpress.org/browser/tags/6.9.4/src/wp-admin/includes/misc.php#L1619)
[View on GitHub](https://github.com/WordPress/wordpress-develop/blob/6.9.4/src/wp-admin/includes/misc.php#L1619-L1619)

## 󠀁[Related](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#related)󠁿

| Used by | Description | 
| [wp_check_php_version()](https://developer.wordpress.org/reference/functions/wp_check_php_version/)`wp-admin/includes/misc.php` |

Checks if the user needs to update PHP.

  |

## 󠀁[Changelog](https://developer.wordpress.org/reference/hooks/wp_is_php_version_acceptable/?output_format=md#changelog)󠁿

| Version | Description | 
| [5.1.1](https://developer.wordpress.org/reference/since/5.1.1/) | Introduced. |

## User Contributed Notes

You must [log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fhooks%2Fwp_is_php_version_acceptable%2F)
before being able to contribute a note or feedback.