Title: xmlrpc_enabled
Published: April 25, 2014
Last modified: April 28, 2025

---

# apply_filters( ‘xmlrpc_enabled’, bool $is_enabled )

## In this article

 * [Description](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/?output_format=md#description)
 * [Parameters](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/?output_format=md#parameters)
 * [Source](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/?output_format=md#source)
 * [Related](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/?output_format=md#related)
 * [Changelog](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/?output_format=md#changelog)
 * [User Contributed Notes](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/?output_format=md#user-contributed-notes)

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

Filters whether XML-RPC methods requiring authentication are enabled.

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

Contrary to the way it’s named, this filter does not control whether XML-RPC is 
_fully_ enabled, rather, it only controls whether XML-RPC methods requiring authentication–
such as for publishing purposes – are enabled.

Further, the filter does not control whether pingbacks or other custom endpoints
that don’t require authentication are enabled. This behavior is expected, and due
to how parity was matched with the `enable_xmlrpc` UI option the filter replaced
when it was introduced in 3.5.

To disable XML-RPC methods that require authentication, use:

    ```php
    add_filter( 'xmlrpc_enabled', '__return_false' );
    ```

For more granular control over all XML-RPC methods and requests, see the [‘xmlrpc_methods’](https://developer.wordpress.org/reference/hooks/xmlrpc_methods/)
and [‘xmlrpc_element_limit’](https://developer.wordpress.org/reference/hooks/xmlrpc_element_limit/)
hooks.

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

 `$is_enabled`bool

Whether XML-RPC is enabled. Default true.

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

    ```php
    $this->is_enabled = apply_filters( 'xmlrpc_enabled', $is_enabled );
    ```

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

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

| Used by | Description | 
| [wp_xmlrpc_server::set_is_enabled()](https://developer.wordpress.org/reference/classes/wp_xmlrpc_server/set_is_enabled/)`wp-includes/class-wp-xmlrpc-server.php` |

Sets wp_xmlrpc_server::$is_enabled property.

  |

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

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

## 󠀁[User Contributed Notes](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/?output_format=md#user-contributed-notes)󠁿

 1.  [Skip to note 2 content](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/?output_format=md#comment-content-5839)
 2.   [joho68](https://profiles.wordpress.org/joho68/)  [  4 years ago  ](https://developer.wordpress.org/reference/hooks/xmlrpc_enabled/#comment-5839)
 3. [You must log in to vote on the helpfulness of this note](https://login.wordpress.org?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fhooks%2Fxmlrpc_enabled%2F%23comment-5839)
    Vote results for this note: 0[You must log in to vote on the helpfulness of this note](https://login.wordpress.org?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fhooks%2Fxmlrpc_enabled%2F%23comment-5839)
 4. The last link above, “https://developer.wordpress.org/reference/hooks/xmlrpc_element_limit”,
    is broken.
 5.  [Log in to add feedback](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fhooks%2Fxmlrpc_enabled%2F%3Freplytocom%3D5839%23feedback-editor-5839)

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