WP Manifestindependent plugin directory
manifest / forms / gf-domain-restriction

GF Domain Restriction

Restrict Gravity Forms submissions by email domain. Whitelist, blacklist, and request approval for unknown domains.

by Your Name · github.com/managingwp/gf-domain-restriction · website

0stars
0forks

Install

No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:

wp plugin install https://github.com/managingwp/gf-domain-restriction/archive/refs/heads/main.zip

Readme

GF Domain Restriction

A WordPress plugin to restrict Gravity Forms submissions by email domain.

Features

  • Whitelist domains that are always allowed
  • Blacklist domains that are always blocked
  • Pending approval queue for unknown domains — you get an email notification and can approve/deny from the admin
  • Whitelist-only mode — block all domains not explicitly whitelisted (no approval requests)
  • Apply restrictions to a specific form or all forms
  • Custom error messages for blocked and pending submissions

Installation

  1. Upload the gf-domain-restriction folder to /wp-content/plugins/
  2. Activate the plugin in Plugins → Installed Plugins
  3. Go to Settings → GF Domain Restriction to configure

Configuration

Setting Description
Form ID The ID of the form to restrict. Leave blank for all forms.
Email Field ID The field ID of the email field in your form.
Notification Email Where to send approval request emails.
Whitelist-Only Mode Block all non-whitelisted domains without sending approval requests.
Whitelisted Domains One domain per line — always allowed.
Blacklisted Domains One domain per line — always blocked.
Blocked Message Inline error shown when a blacklisted domain is used.
Pending Message Inline error shown when an unknown domain submits.

How It Works

  1. User submits a form with their email address
  2. Plugin extracts the domain (e.g. gmail.com from user@gmail.com)
  3. If domain is whitelisted → submission allowed ✅
  4. If domain is blacklisted → submission blocked with error ❌
  5. If domain is unknown → submission blocked, domain queued for review, admin notified via email 📧
  6. Admin visits Settings → GF Domain Restriction to approve, deny, or dismiss pending domains
  7. Approving adds the domain to the whitelist; denying adds it to the blacklist

Requirements

  • WordPress 5.8+
  • Gravity Forms (any recent version)
  • PHP 7.4+

Read the full README on GitHub →