Skip to content

SJ Gravity Forms Blocklist: A Gravity Forms Plugin to Block Website URLs, Email and Domains Extensions.

SJ Gravity Forms Blocklist is a lightweight WordPress plugin built to extend Gravity Forms with simple but powerful spam-blocking features. Designed with freelancers, developers, and digital agencies in mind, this plugin helps protect your WordPress site from unwanted form submissions by blocking specific website URLs, email addresses, and email domain extensions.

If you’re tired of dealing with spam through your Gravity Forms, this plugin gives you an easy way to take back control. It’s particularly useful for those offering ongoing WordPress maintenance and support, where reliable anti-spam protection is key for client sites.

This plugin works silently in the background by hooking into all Gravity Forms on your site. It prevents submissions from known spam sources using your custom blocklists. Whether it’s blocking disposable email addresses, spammy URL shorteners, or whole country domain extensions like .ru, the Gravity Forms Blocklist plugin keeps things clean and simple.

How to Set Up the Gravity Forms Blocklist Plugin

There’s no separate settings panel at this stage, in keeping with its developer-friendly design. All configuration is currently handled via your wp-config.php file. Here’s how to set it up:

define( 'SJGFBLOCKLIST_URLS', [ 'tinyurl.com', 'bit.ly' ] );
define( 'SJGFBLOCKLIST_EMAILS', [ '[email protected]' ] );
define( 'SJGFBLOCKLIST_EXTENSIONS', [ 'ru', 'cn' ] );

Add the above before this line:

/* That's all, stop editing! Happy publishing. */

Block User Registration and WooCommerce Spam

The plugin applies to all Gravity Forms by default. Future updates will let you choose specific forms and manage settings more easily. That extra control matters if your site uses Gravity Forms for things like user registration or product-based forms.

When you use the Gravity Forms User Registration Add-On, spam signups can quickly become a problem. This plugin helps stop those accounts before the form is submit. It checks each entry and rejects anything that matches your custom blocklist. That helps keep your user database clean and saves time dealing with fake registrations.

You’ll also benefit if your WooCommerce store uses the Gravity Forms Product Add-Ons extension. These forms often collect extra details like measurements, notes, or uploads. Spammers try to abuse that. With this plugin, unwanted entries never reach the checkout. You keep your order process smooth and free from WooCommerce spam.

By adding SJ Gravity Forms Blocklist to your website, you take a step towards control of form spam. It works quietly in the background and supports the forms that matter most.

You can download SJ Gravity Forms Blocklist directly from GitHub. Unzip the file, rename the folder to sjgravityformsblocklist, and move it to your wp-content/plugins directory.

If you have any questions or need help with WordPress development or plugin support, get in touch today.