Plan Logic

Article author
Duncan Hamra

Welcome to this article where I'll introduce you to an exciting feature that simplifies plan management on our site.

Plan Logic is a powerful tool that allows you to automatically adjust customer plans based on customizable conditions, similar to using IF .... THEN ... statements.

Important: Please note that the Plan Logic feature is designed for free plans. With paid plans, the only available action is to cancel all recurring plans, which will also cancel any other paid plans the member has.

Use Cases

Let's explore some examples to understand the potential of Plan Logic.

Case 1: Upgrading to a Lifetime Plan

Imagine you offer both a monthly plan and a lifetime plan on your site. When a member decides to upgrade from the monthly plan to the lifetime plan, you want to automatically cancel the monthly subscription. Plan Logic can handle this process for you seamlessly.

By creating a Plan Logic rule that cancels any recurring prices when an existing member purchases the lifetime plan, you can ensure that once the member completes the checkout, the monthly subscription is automatically canceled. This prevents any further billing for the original plan.

Case 2: Switching Between Free Plans

Let's say you have multiple free plans, such as a teacher plan and a student plan. To ensure that a member can only be enrolled in one free plan at a time, Plan Logic can be of great help.

To set this up, you can create two Plan Logic rules:

  1. When Free Plan 1 is added, remove Free Plan 2.
  2. When Free Plan 2 is added, remove Free Plan 1.

With this setup, whenever a member switches between free plans, they will be automatically removed from the previous plan, ensuring they are enrolled in only one free plan at a time.

Creating Logic for Plan Purchases

Let's learn how to create logic statements for plan purchases:

  1. Log in to your Memberstack account and navigate to the Plans section in the side menu.
  2. Select a plan name from the list in the center window.
  3. Expand the Plan Logic folder.

Now you have several options to add or remove items based on specific conditions.


  • Note: Plan Logic only runs when a member's information is updated, not when a member is initially created.

Adding plans

When a customer purchases a plan, you can also add additional benefits or features. For example, you could offer 30 days of free access to a premium plan when a customer purchases a specific plan.

  1. Select a plan and expand the Plan Logic folder.
  2. Click the "Add" button under the When plan is purchased then section.
  3. Select one or more options from the drop-down menu.
  4. Click "Save".


  • By the way: You can also automatically add a plan when a customer cancels a plan.


Removing plans and prices

In addition to adding plans, you can also remove plans or cancel prices using Plan Logic. Here are the steps:

  1. To remove a free plan, click the Remove field.
  2. Select one or more options from the drop-down menu.
  3. Click "Save".


  • You can also choose to remove all free plans by toggling the corresponding option.


Instead of removing a free plan, you can also cancel one or more prices (i.e., paid plans) using Plan Logic. Here's how:

  1. To cancel a price, click the Cancel field.
  2. Select one or more options from the drop-down menu.
  3. You can also choose to cancel all prices by toggling the corresponding option.
  4. Click "Save".


Creating Logic for Cancelled Plans

Plan Logic can also be used to add or remove plans (or cancel prices) when a customer cancels a plan. Here's how:

  1. Expand the Plan Logic folder.
  2. Scroll down to the When plan is cancelled then section.
  3. Follow the same steps described above to add, remove, or cancel plans or prices.
  4. Click "Save".



Plan Logic is a versatile and powerful tool that can greatly simplify your plan management. With its flexibility and automation, you can save time and create a seamless experience for your members. We hope this article has provided you with a clear understanding of Plan Logic and how it can benefit your project.

Thank you for reading, and have a great day!

Was this article helpful?



  • Comment author
    Robert Navaille
    • Edited

    Hey there Duncan-Hamra; I noticed that turning on the switch to cancel all paid plans upon subscription of a paid plan also cancels the subscription that triggers the cancelation. 

    I recognize that there may be a case for this (i.e. I'm moving from a paid plan to a free plan). The gap I'm seeing in memberstack is highlighted by my use case. 

    I have ~20 unique subscriptions and only one can be active at any time so essentially I want to be able to say "Cancel All Except Plan XYZ". Without that, I need to configure each of the 20 subscriptions to cancel the other 19 when a user switches plans. 

    Happy to talk about my use case more if it'll be helpful to you guys. 

  • Comment author
    Duncan Hamra

    Oh interesting!! Tyler Bell is this an order of operations bug or intended behavior?

    Robert Navaille Thanks for bringing this to our attention. You are correct that we really only intended for this feature to be used when switching from a recurring plan to a one-time or free plan... but I see what you want to do.

  • Comment author
    Tyler Bell

    Robert Navaillea We are actively working on a fix for this 🙂 Thanks for reporting!

    The fix should be live Monday 👍


Please sign in to leave a comment.