REST API Guard icon
Security

REST API Guard

Restrict and control anonymous access to the WordPress REST API, with optional JSON Web Token (JWT) authentication.

Developer Sean Fisher
31 Needs attentionmaintenance
  • 16 yearson WordPress.org
  • 5plugins
  • 10,290+installs in total
  • 4.0★avg. rating (58)
  • 20%of plugins updated this year
3/14 badges Profile →

Is REST API Guard safe to install?

Good choice: actively maintained

  • Pass: Actively maintained Last updated 1 month ago (version 1.5.0).
  • Pass: Compatible with current WordPress Tested up to WordPress 7.1; the current release is 7.1. Needs PHP 8.3+.
  • Note: Few reviews so far 2 ratings on WordPress.org.
  • Note: Small user base Active on 200+ sites.

Check every plugin on your site with the free WordPress plugin checker →

Based on WordPress.org data, checked Nov 19, 2026. Always keep plugins updated and test changes on a staging site.

Overview

REST API Guard describes itself as: “Restrict and control anonymous access to the WordPress REST API, with optional JSON Web Token (JWT) authentication.”

It is active on 200+ WordPress sites and rated 5.0 out of 5 by 2 users on WordPress.org. Developers can extend it through 0 actions and 17 filters, listed below.

We haven't published a hands-on review of REST API Guard yet. Want one, or need help with it? Send us a request.

How to install REST API Guard

  1. Open the plugin installer. In your WordPress dashboard go to Plugins → Add New Plugin.
  2. Search for it. Type “REST API Guard” and pick the one by Sean Fisher.
  3. Install and activate. Click Install Now, then Activate.
Install with a zip file or WP-CLI

Download the zip from the WordPress.org plugin page, then go to Plugins → Add New Plugin → Upload Plugin, choose the file and click Install Now. Or from the command line:

wp plugin install rest-api-guard --activate

Requirements: WordPress 6.5+ · PHP 8.3+ · tested up to WordPress 7.1.5

Hooks & customisation

REST API Guard 1.5.0 fires 0 actions and 17 filters. Use them from your child theme or a snippets plugin to change how it behaves without editing its files.

rest-api-guard — top hooks
// Check if the anonymous request requires a JSON Web Token (JWT).
apply_filters( 'rest_api_guard_authentication_jwt', $settings['authentication_jwt'] ?? false, $request );

// Prevent access to the root of the REST API.
apply_filters( 'rest_api_guard_allow_index_access', $settings['allow_index_access'] ?? false, $endpoint );

// Prevent access to the namespace index of the REST API.
apply_filters( 'rest_api_guard_allow_namespace_access', $settings['allow_namespace_access'] ?? false, substr( $endpoint, 1 ) );

// Filter whether to accept JWTs that were issued before tokens were tracked.
apply_filters( 'rest_api_guard_allow_untracked_jwt', true, $decoded );

// Prevent access to the /wp/v2/users endpoints by default.
apply_filters( 'rest_api_guard_allow_user_access', $settings['allow_user_access'] ?? false, $endpoint );

// Filter the allowlist for allowed anonymous requests.
apply_filters( 'rest_api_guard_anonymous_requests_allowlist', $settings['anonymous_requests_allowlist'] ?? [] );

Browse all 17 hooks with examples →

REST API Guard: frequently asked questions

Is REST API Guard free?

Yes. REST API Guard is free to download from the official WordPress.org plugin directory and is licensed under the GPL, so you can use it on as many sites as you like. Some developers sell a separate Pro version or paid add-ons; check the developer's website for details.

Is REST API Guard safe to use?

REST API Guard is actively maintained: the latest version was released 1 month ago. As with any plugin, keep it updated and only install it from WordPress.org or the developer.

Does REST API Guard work with WordPress 7.1?

Yes. REST API Guard is tested up to WordPress 7.1, the current release. It requires WordPress 6.5 or later and PHP 8.3 or later.

How many websites use REST API Guard?

REST API Guard is active on 200+ WordPress sites, according to WordPress.org. It is currently at version 1.5.0, last updated on October 13, 2026.

What are the best alternatives to REST API Guard?

Plugins that do a similar job and are actively maintained include JWT Authentication for WP REST API (50,000+ installs), Disable WP REST API (30,000+ installs), JWT Authentication for WP REST APIs (10,000+ installs).

Can I customise REST API Guard without editing its code?

Yes. REST API Guard 1.5.0 fires 0 actions and 17 filters that you can use from a child theme or a code snippets plugin, so your changes survive plugin updates. Browse all 17 hooks with examples.

Done for you

Need REST API Guard to do more?

Clear starting prices, an exact quote before any work, and changes built so plugin updates never wipe them.

Custom hook snippet

from $49

A small, update-safe change built on the plugin’s own hooks.

  • Code written against the plugin’s actions and filters
  • Tested on a staging copy of your site
  • Install instructions included

Typical turnaround: 2–3 business days

Choose this

Bug or conflict fix

from $79

Errors, broken layouts or two plugins that don’t get along.

  • Find the cause on a staging copy
  • Fix without breaking updates
  • Explain what was wrong

Typical turnaround: 1–3 business days

Choose this

Not sure which fits? Describe what you need and we’ll suggest the simplest option.

Need REST API Guard customised?

Tell us what you want changed, added or fixed and we'll reply with an estimate.

WP EXPERTS is independent and not affiliated with Sean Fisher. Plugin names and logos belong to their owners. Version, rating and install figures from WordPress.org, checked Nov 19, 2026.

More plugins by Sean Fisher

All 5 →
Not updated in 8+ years

Lockdown WP Admin conceals the administration and login screen from intruders. It can hide WordPress Admin (/wp-admin/) and and login…

10,000+ installs Updated 9 years ago 9 hooks
Not updated in 13+ years

Adding Composer dependency management to WP CLI.

70+ installs Updated 13 years ago 2 hooks
Not updated in 16+ years

Running a WordPress MU network can be annoying when sites can be submitting different pings lists. The site will allow…

10+ installs Updated 16 years ago
Not updated in 16+ years

We are going to enable the WordPress ping service for each site in a WordPress MU Network. This allows each…

10+ installs Updated 16 years ago

Alternatives in Security

See all →
Reviewed

The best anti-spam protection to block spam comments and spam in a contact form. The most trusted antispam solution for…

5+ million installs Updated 3 months ago 43 hooks

Firewall, Malware Scanner, Two Factor Auth, and Comprehensive Security Features, powered by our 24-hour team. Make security a priority with…

5+ million installs Updated 2 weeks ago 98 hooks

Easily improve site security with WordPress Hardening, Two-Factor Authentication (2FA), Login Protection, Vulnerability Detection and SSL certificate.

3+ million installs Updated 4 weeks ago 116 hooks

Simplified WordPress management. Manage site info, maintenance, security, & redirects.

3+ million installs Updated 5 days ago 7 hooks