⏱️ TL;DR
What is Plan Logic? A set of automated "IF/THEN" rules inside your Memberstack Dashboard that controls what happens to other plans when a member joins or leaves a plan.
Why use it? It prevents members from holding conflicting plans simultaneously (e.g., holding both a "Free Trial" and a "Premium Plan," or holding both a "Monthly Subscription" and a "Lifetime Plan").
Key Use Cases:
- Free to Paid: Automatically remove a "Free Trial" plan when a paid plan is purchased.
- Recurring to Lifetime: Automatically cancel a recurring monthly subscription when a member buys a lifetime access plan.
- Role Switching: Automatically remove a "Student" free plan if they switch to a "Teacher" free plan.
1. What is Plan Logic?
By default, Memberstack allows members to hold multiple plans at the same time. This is great for modular setups (e.g., buying Course A and Course B separately).
However, for tiered membership sites (Basic, Pro, Premium), you usually want members to have only one active plan at a time.
Plan Logic solves this. Found inside your dashboard under Plans, click on your plan, click Show Advanced at the bottom of the page to reveal advanced settings, and expand the Plan Logic accordion. It lets you configure automated transitions:
2. Recipe 1: Auto-Remove "Free Trial" when Paid Plan is Purchased
If you have a free trial plan that grants temporary access, you don't want it cluttering your member's profile or conflicting with their permissions once they buy a paid plan.
How to set it up:
- Open your Paid Plan settings in Memberstack.
- Click Show Advanced at the bottom of the page to reveal advanced settings.
- Scroll down and expand the Plan Logic accordion.
- Under the When plan is purchased trigger, locate the Remove field and select your Free Trial Plan from the dropdown.
- Click Save in the top right.
The Result:
The moment their payment succeeds and the Paid Plan is added to their account, Memberstack instantly and silently removes the Free Trial plan from their profile. Their gated content access transitions seamlessly.
3. Recipe 2: Upgrade from Recurring Monthly to Lifetime Access
If a loyal monthly subscriber decides to purchase your high-ticket "Lifetime Access" plan, you must ensure their monthly recurring billing is canceled immediately so they aren't charged again next month.
How to set it up:
- Open your Lifetime Access Plan settings in Memberstack.
- Click Show Advanced at the bottom of the page to reveal advanced settings.
- Scroll down and expand the Plan Logic accordion.
- Under the When plan is purchased trigger, locate the Cancel field.
- Toggle on Cancel all recurring plans (or click the dropdown to select specific monthly prices/plans you want to cancel).
[There should be an image here of the Plan Logic cancel settings in the Memberstack dashboard.]
- Click Save in the top right.
The Result:
When the member purchases the Lifetime Access plan, Memberstack automatically communicates with Stripe to cancel their active monthly subscription. The subscription is set to cancel, and they are transitioned to lifetime-only access without any admin intervention.
4. Recipe 3: Switching Between Free Roles (e.g., Student vs. Teacher)
If your platform has different free user types (like "Student" and "Teacher"), you want to ensure that if a user changes their role, they lose access to the old role's content.
How to set it up:
- Open your Teacher (Free) Plan settings.
- Click Show Advanced at the bottom of the page, scroll down, and expand the Plan Logic accordion.
- Under the When plan is added trigger, locate the Remove field and select Student (Free) Plan.
- Click Save in the top right.
- Repeat this process for the other plan: open your Student (Free) Plan settings, click Show Advanced, and expand the Plan Logic accordion.
- Under the When plan is added trigger, locate the Remove field and select Teacher (Free) Plan.
- Click Save in the top right.
The Result:
The two plans are now mutually exclusive. Joining one automatically boots the member out of the other, keeping your gated content permissions perfectly clean.
Tip: The Remove field in Plan Logic only allows you to select free plans. To stop a member's recurring billing for a paid plan, always use the Cancel field instead.
5. The Alternative: Direct Tiered Upgrades (data-ms-price:update)
If you are simply moving a member from a Paid Basic Plan to a Paid Premium Plan, you do not need Plan Logic. Instead, you should use Memberstack's native upgrade/downgrade attribute.
When a member clicks your "Upgrade to Premium" button, you want Stripe to prorate their payment and switch their subscription tier.
The Attribute: Apply the custom attribute data-ms-price:update="[PRICE_ID]" (for example, data-ms-price:update="prc_premium-yearly-12345") to your upgrade button.
How it works: When clicked, Memberstack opens a Stripe Checkout session showing the prorated amount (charging only the difference for the remainder of the billing cycle). Once completed, Stripe updates their existing subscription to the new price tier, keeping their billing cycle and historical invoices intact.
📊 Summary of Plan Transition Methods
| Scenario | Best Tool | Stripe Behavior |
| Free Trial to Paid Plan | Plan Logic (Remove) | No billing impact (removes the free plan). |
| Monthly Subscription to Lifetime | Plan Logic (Cancel) | Cancels the monthly subscription in Stripe. |
| Free Role A to Free Role B | Plan Logic (Remove) | No billing impact (swaps the free plans). |
| Paid Tier A to Paid Tier B | data-ms-price:update attribute | Updates existing subscription with Stripe proration. |
❓ Frequently Asked Questions (FAQ)
Q: Can I use Plan Logic to remove a paid plan when a user purchases another paid plan?
Yes, while it is possible to use plan logic, we recommend using the data-ms-price:update attribute so that your users can get the benefit of proration while switching between two tiered paid plans. In case the user has one or multiple recurring plans and is moving to a lifetime paid plan, then the Plan Logic's 'Cancel all recurring plans' toggle can be used instead.
Q: What happens to a member's gated content access when a plan is removed via Plan Logic?
The access is revoked instantly. If Plan A granted access to /dashboard and Plan B grants access to /premium-dashboard, removing Plan A via Plan Logic means they will immediately be blocked from /dashboard and redirected if they try to visit it.
Q: Does Plan Logic work if I manually add a plan to a member from the dashboard?
Yes. Plan Logic rules trigger regardless of how the plan was added—whether the member bought it on your site, signed up for a free plan, or if you (the admin) manually added the plan to their profile inside the Memberstack Dashboard.
Comments
No comments yet. Start the conversation below.
Please sign in to leave a comment.