Memberstack now supports self-service account deletion for your members. This feature allows members to delete their own accounts without requiring admin intervention, while automatically handling subscription cancellations.
How It Works
When a member deletes their account:
- The member is immediately logged out
- Their account is permanently deleted from Memberstack
- Any active recurring subscriptions are automatically cancelled
- Their Stripe customer profile remains intact (not deleted) by default
Enabling Account Deletion in Your Dashboard
Important: Member self-deletion is disabled by default for all sites and must be enabled:
- Log in to your Memberstack dashboard
- Navigate to "Settings" in the left sidebar
- Scroll down to the "Security" section
- Find the "Allow members to delete their account" toggle
- Switch the toggle to the enabled position (green)
Once enabled, members will be able to delete their accounts either through the prebuilt profile modal or your custom implementation.
Optional: Stripe Customer Deletion
You can also choose to delete the member's Stripe customer profile when they delete their account:
- After enabling the "Allow members to delete their account" toggle
- Find the "Delete Stripe customer on self-deletion" toggle directly below
- Enable this toggle if you want the member's Stripe customer profile and subscriptions to be completely removed
Note: By default, when this option is disabled, Memberstack preserves the Stripe customer profile while still cancelling any active subscriptions.
Implementation Options
Once you've enabled account deletion in your dashboard, there are two ways to implement this feature for your members:
1. Using the Prebuilt Profile Modal
The simplest implementation is to use Memberstack's prebuilt profile modal, which automatically includes a "Delete Account" option:
When enabled, the delete button appears in the prebuilt profile modal under the Security tab for all logged-in members.
Built-in Confirmation Dialog
The prebuilt profile modal automatically displays a confirmation dialog before completing the deletion:
This dialog warns members that:
- The action cannot be undone
- They will be logged out
- Their account will be deleted
2. Custom Implementation with Data Attributes
For sites with custom member dashboards, you can implement the delete functionality using our data attribute:
data-ms-action="delete-member"
This attribute can be added to any clickable element (like buttons or links) and will trigger the account deletion process when clicked.
Important: The data attribute approach does not automatically show a confirmation dialog. You must implement your own confirmation process to prevent accidental deletions.
Recommended: Two-Step Confirmation Process
Here's a ready-to-use button component you can copy and paste directly into your Webflow project.
To implement your own two-step confirmation process:
- Create an initial "Delete Account" button without the data attribute:
<button id="show-delete-modal">Delete Account</button>
- When clicked, display your custom confirmation modal with the actual delete button:
<div id="delete-confirmation-modal" style="display: none;"> <h3>Are you sure you want to delete your account?</h3> <p>This action cannot be undone. All your data will be permanently deleted.</p> <button data-ms-action="delete-member">Yes, Delete My Account</button> <button id="cancel-delete">Cancel</button> </div>
This approach adds an extra confirmation step before the irreversible deletion process is triggered, significantly reducing the risk of accidental deletions.
FAQ
Q: Will deleting an account remove the member's Stripe customer profile?
A: By default, no. The Stripe customer profile remains intact unless you enable the "Delete Stripe customer on self-deletion" toggle in your dashboard settings.
Q: Can deleted accounts be recovered?
A: No, account deletion is permanent and cannot be undone.
Q: Are subscriptions automatically cancelled?
A: Yes, any recurring subscriptions associated with the account are automatically cancelled in Stripe.
Q: Can I customize the confirmation dialog in the prebuilt modal?
A: Currently, the confirmation dialog in the prebuilt modal is not customizable. If you need a custom confirmation experience, use the data attribute approach instead.
Q: Do members receive an email notification when their account is deleted?
A: No, Memberstack does not automatically send notification emails when accounts are deleted.
Comments
3 comments
Hi,
thanks that is a beneficial application.
Is this also working in the test mode? Because for me it is not working
Thanks for your help.
Best,
Georg
And in the button to copy, you use "delete-member" instead of "delete-account"
I just get a message saying 'Please contact the website owner to delete your account.'
Please sign in to leave a comment.