How to disable or enable the REST API endpoint in Yoast SEO
In Yoast SEO 14.0, we introduced a REST API endpoint that will give you all the necessary metadata for a specific URL. This makes it easier for headless WordPress sites to use Yoast SEO for their SEO meta output. In this article, we’ll explain how to disable or enable this feature in the Yoast SEO plugin.
Read more about the REST API head endpoint and what it is here:
How to disable or enable the REST API head endpoint
The REST API head endpoint feature is enabled by default. If you don’t want this API on your site, you can easily disable it by following the steps below.
- Log in to your WordPress website.
When you’re logged in, you will be in your ‘Dashboard’.
- Click on ‘SEO’.
On the left-hand side, you will see a menu. In that menu, click on ‘SEO’.
- Click on ‘Features’ in the General settings.
On the Yoast SEO General settings page, go to the ‘Features’ tab.
- To disable the API, switch the toggle for ‘REST API: Head endpoint’ to ‘Off’.
The toggle for this API is set to ‘On’ by default. To disable the REST API head endpoint, switch the toggle to ‘Off’.
- If you want to enable the API again, simply switch the toggle back to ‘On’.
To enable to REST API head endpoint again, switch the toggle to ‘On’.
- Click ‘Save changes’.