Plugin Directory

Test out the new Plugin Directory and let us know what you think.

Disable REST API

Disable the use of the JSON REST API on your website to anonymous users.

** As of WordPress 4.7, the filter provided for disabling the REST API has been removed. However, this plugin will now forcibly return an authentication error to any API requests from sources who are not logged into your website, which will effectively still prevent unauthorized requests from using the REST API to get information from your website **

The REST API is a project in development via the JSON REST API plugin by Ryan McCue, Rachel Baker, Daniel Bachhuber and Joe Hoyle. The engine for the API has existed in WordPress since v4.4, but additional functionality and endpoints are a continual project. While this is very exciting news for many reasons, it is also not functionality that every site admin is going to want enabled on their website if not necessary.

For WordPress versions 4.4, 4.5 and 4.6, this plugin makes use of the rest_enabled filter provided by the API to disable the API functionality. For WordPress 4.7+, the plugin will return an authentication error (effectively disabling all endpoints) for any user not logged into the website.

Requires: 4.0 or higher
Compatible up to: 4.7.3
Last Updated: 4 months ago
Active Installs: 20,000+


5 out of 5 stars


3 of 4 support threads in the last two months have been marked resolved.

Got something to say? Need help?


Not enough data

0 people say it works.
0 people say it's broken.