---
title: "Settings Reference"
description: "Reference for all Login for Stripe Customer Portal admin settings and option keys."
url: "https://docs.customerportalplugin.com/configuration/settings-reference/"
---
Configure the plugin under **Stripe Portal** in the WordPress admin (`/wp-admin/admin.php?page=login-stripe-customer-portal`).

Each setting includes contextual **Learn more** links to this documentation. A **Documentation** and **Support forum** footer appears at the bottom of the page.

![Stripe Portal settings page](../../assets/images/admin-settings-page.png)

## Stripe Secret Key

<table><tbody><tr><td><strong>Option key</strong></td><td><code>lscp_stripe_api_key</code></td></tr><tr><td><strong>Field type</strong></td><td>Password (masked after save)</td></tr><tr><td><strong>Required</strong></td><td>Yes</td></tr></tbody></table>

Your Stripe **Secret API key** (`sk_test_...` or `sk_live_...`). Get it from **Stripe Dashboard → Developers → API keys**.

After you save, the key is displayed as a **fixed-length mask** (12 `●` characters) in the admin — the mask never reveals the real key length via view source. Leaving the field masked on a subsequent save keeps the existing stored key.

Never share your Secret key or commit it to version control. The settings page enforces the `manage_options` capability, so only WordPress administrators can view or change it.

## Redirect URL

<table><tbody><tr><td><strong>Option key</strong></td><td><code>lscp_stripe_redirect_url</code></td></tr><tr><td><strong>Field type</strong></td><td>URL</td></tr><tr><td><strong>Default</strong></td><td>Customer portal page URL (<code>/{slug}/</code>)</td></tr></tbody></table>

The URL Stripe sends customers to when they **exit** the Customer Portal (`return_url` on the Billing Portal session).

**Intended behavior:** After a customer finishes in the portal, they return to this URL — often your portal login page or a "Thank you" page on your site.

## Customer Portal Slug

<table><tbody><tr><td><strong>Option key</strong></td><td><code>lscp_stripe_endpoint_slug</code></td></tr><tr><td><strong>Field type</strong></td><td>Text (sanitized as slug)</td></tr><tr><td><strong>Default</strong></td><td><code>customer-portal</code></td></tr></tbody></table>

The URL slug for the dedicated login page. With default settings, the login page is:

`https://yoursite.com/customer-portal/`

Leave empty to **disable** the dedicated endpoint (shortcode-only mode). Input is sanitized through `sanitize_title` and capped at **64 characters** to keep the rewrite engine bounded.

After changing the slug, go to **Settings → Permalinks** and click **Save Changes** to flush rewrite rules.

## Only allow existing Stripe customers to login

<table><tbody><tr><td><strong>Option key</strong></td><td><code>lscp_stripe_validate_existing_customers</code></td></tr><tr><td><strong>Field type</strong></td><td>Checkbox (<code>0</code> or <code>1</code>)</td></tr><tr><td><strong>Default</strong></td><td>Off (<code>0</code>)</td></tr></tbody></table>

When **checked**:

*   The plugin checks Stripe for a customer with the submitted email before sending a magic link.
*   If no customer exists, **no email is sent**.
*   The visitor sees the conditional message: *“If your email address is associated with a Stripe customer, a login link is on its way. Please check your inbox.”* — identical for known and unknown emails, so the form does not reveal Stripe customer existence.

When **unchecked** (default):

*   Any valid email can request a login link.
*   If no Stripe customer exists for that email, the plugin **creates a new Stripe Customer** when the magic link is redeemed.
*   The visitor sees a direct message: *“A login link is on its way. Please check your inbox for the link to access your Stripe Customer Portal.”* — no longer the misleading “If your email address is registered…” wording from earlier versions.

Either mode is paired with a per-email + per-IP rate limiter (5 requests / 10 minutes) so the form can’t be abused as a mail relay or as an enumeration oracle against your Stripe customer list. See [Security and Privacy](../../security-and-privacy/security-and-privacy/).

## Information shown after save

Below the settings form, the admin page displays:

1.  **Customer Portal URL** — Direct link to your login endpoint (when slug is set).
2.  **Permalink reminder** — Link to **Settings → Permalinks**.
3.  **Shortcode** — `[login-stripe-customer-portal]` for embedding the form elsewhere.

![Portal URL, permalinks note, and shortcode on settings page](../../assets/images/admin-settings-saved-url.png)

## Related docs

[Customer Portal Endpoint›](../../usage/customer-portal-endpoint/) [Shortcode›](../../usage/shortcode/)
