WPSubscription now includes a robust Role Management system that automatically updates user roles based on the status of their subscription. This helps you control access to content, features, or permissions depending on whether a user has an active, expired, or cancelled subscription.


How Role Management Works

Whenever a subscription status changes, WPSubscription will automatically update the user's WordPress role using the following logic:

Subscription Status

Assigned Role

active

Subscriber Default Role (from settings)

expired, cancelled, pe_cancelled

Subscriber Inactive Role (from settings)

This ensures that only users with valid subscriptions retain access to protected features or content, while inactive users are downgraded automatically.


Settings Configuration

To manage subscription-based roles, configure the following settings:

  1. Go to: WP Admin → WP Subscription → Settings

  2. Set roles:

    • Subscriber Default Role: Assigned when a subscription becomes active.

    • Subscriber Inactive Role: Assigned when a subscription is cancelled or expired.

You can use any existing WordPress role or a custom role that suits your site’s access control strategy.


When Roles Are Updated

  • After order status changes (activation, expiry, cancellation)

  • During subscription updates triggered manually or via automation

  • Immediately after a subscription is resumed or reactivated


Use Cases

  • Restrict content access to active subscribers only

  • Downgrade expired users to a limited-access role

  • Grant additional permissions to paid users by assigning premium roles

  • Automatically manage member group visibility in forums or communities


Best Practices

  • ✅ Ensure your role settings are saved correctly

  • ✅ Create a dedicated role (e.g., inactive_subscriber) with limited access

  • ✅ Avoid assigning administrator-level roles through this system

  • ✅ Test role changes using test subscriptions before applying to live users


This role management system helps automate access control and improve the subscriber experience by aligning user permissions with their subscription status.