Disabling REST API for JSON in WordPress
Learn how to disable REST API in WordPress. This article shows you how to use the Disable REST API plugin to whitelist endpoints registered with the REST API.
The WordPress REST API allows developers to interact with sites remotely by sending and receiving JSON (JavaScript Object Notation) objects. Although the REST API is useful for developers, most WordPress site owners may not need it all. The WordPress REST API is also known to slow down the site and opens up for DDOS attacks, and these are probably valid reasons to disable the REST API. Disable REST API is a plugin that allows you to control access points to the WordPress REST API without touching the functions.php file. This article shows you how to use the Disable REST API plugin to manage and whitelist endpoints registered with the WordPress REST API.
Installing Disable REST API Plugin for WordPress
To install and configure Disable REST API plugin, follow these steps:
-
Log in to your WordPress site with an administrator account.
-
On the Dashboard in the left sidebar, click Plugins and then click Add New:
-
Search for "Disable REST API" click Install, and then click Activate the plugin:
-
To access the plugin, in the main menu, click on Settings, and then click on Disable REST API:
-
Select and whitelist endpoints registered with the REST API:
-
Click on Save to save the changes. If you need to reset changes,click on Reset Whitelisted:
Related Articles
Updated 3 days ago