WP SmartPay lets you restrict payment forms to logged-in WordPress users only. When this toggle is on, a visitor who is not logged in sees a login prompt instead of the checkout form. Only after signing in do they reach the payment fields.

When to Use It

  • Member-only purchases — Donations or products available only to existing members of your community.
  • Gated subscriptions — Requiring an account ensures every subscriber has a WP user record, making it easy to grant or revoke access.
  • Preventing duplicate accounts — When the payment is linked to a specific user's history, login-gating keeps the customer record clean.

Enabling the Requirement

  1. Open the form: SmartPay → Forms → Edit.
  2. In the right sidebar, expand the Options panel.
  3. Toggle Require Login to on.
  4. Click Update to save.

What the Visitor Sees

When a logged-out user visits a page with this form, they see a login form rendered by the [smartpay_user_login] shortcode instead of the payment checkout. After they log in successfully, they are redirected back to the payment page and the checkout form appears.

Note: The login form on the checkout page uses the SmartPay frontend login shortcode, not the standard WordPress login page. Make sure you have set a Login Page in SmartPay → Settings → General that contains the [smartpay_user_login] shortcode — this is the page the visitor is redirected to when they are not logged in.

Redirect After Login

SmartPay passes the original checkout page URL as a redirect parameter on the login form. After a successful login the visitor is automatically sent back to the page where the payment form is embedded, with the checkout now visible.

Letting Users Register Instead

If you also want unregistered visitors to sign up and pay, place the [smartpay_user_registration] shortcode on the same login page — or on a separate registration page linked from it. The registration form creates a standard WordPress user account and logs the visitor in automatically.