The WordPress WooCommerce Subscriptions plugin enhances WooCommerce by introducing a subscription management system that controls access to content based on active user subscriptions. It allows administrators to define subscription products with custom durations (e.g., days, months, years) and periods via product settings. Upon order completion, the plugin calculates and stores subscription expiry dates for users, using a custom post type or user meta data for tracking. Subscriptions are displayed in the WordPress admin user profile and on a dedicated “Subscriptions” endpoint in the WooCommerce My Account page.
The plugin includes a meta box for posts and pages, enabling administrators to restrict content access to users with valid subscriptions for specific products, with optional redirects to a designated page for unauthorized users. Integrated with Polylang for multilingual support, it ensures product IDs align with the default language. The plugin provides a secure, user-friendly interface with Select2 for product selection and supports WooCommerce’s custom order tables, making it ideal for membership or subscription-based content platforms.
Features of WordPress WooCommerce Subscriptions
- Subscription Product Settings: Add duration and period (day, month, year) fields to WooCommerce products for subscription-based offerings.
- Automatic Subscription Creation: Generates subscriptions with expiry dates upon order completion, factoring in product quantity and duration.
- Content Access Control: Restricts access to posts or pages based on active subscriptions, with configurable redirects for unauthorized users.
- User Subscription Display: Shows subscription details (order, product, quantity, period, start/end dates, payment) in the WordPress admin user profile and My Account page.
- My Account Integration: Adds a “Subscriptions” endpoint to the WooCommerce My Account page for users to view their active subscriptions.
- Polylang Compatibility: Ensures subscription products are correctly identified in the default language for multilingual sites.
- Meta Box for Content Restriction: Allows selection of subscription products and a redirect page/post in a meta box for posts and pages, using Select2 for enhanced usability.
- Secure Data Handling: Implements nonce verification, sanitization, and permission checks for meta box saving and subscription processing.
- Localization Support: Includes translatable strings for multilingual compatibility.
- Custom Order Tables Support: Declares compatibility with WooCommerce’s custom order tables for seamless integration.
Installation
- Upload the plugin folder to the
/wp-content/plugins/directory. - Activate the WordPress WooCommerce Subscriptions plugin through the WordPress admin panel.
- Ensure WooCommerce is installed and activated.
- Configure subscription products by adding duration and period in the product edit screen under the “Inventory” tab.
- Add the
shortcode to a page to enable the “Subscriptions” endpoint.Login
- (Optional) Install Polylang for multilingual support and configure the default language.
- Restrict content by selecting subscription products and a redirect page in the meta box on post/page edit screens.
Usage of WordPress WooCommerce Subscriptions
- Set Up Subscription Products: In the product edit screen, enter a subscription duration (e.g., “30”) and period (e.g., “day”) under the “Inventory” tab to create a subscription product.
- Purchase Subscriptions: When a user completes an order with a subscription product, the plugin calculates the expiry date based on quantity and duration, storing it in user meta and/or a custom post type.
- View Subscriptions:
- Admins can view user subscriptions in the WordPress user profile under the “Subscriptions” section.
- Users can view their subscriptions on the My Account page under the “Subscriptions” tab, showing order details, product, quantity, period, dates, and payment.
- Restrict Content: In the post/page edit screen, use the “Subscriptions” meta box to select subscription products required for access and a redirect page for unauthorized users.
- Manage Access: The plugin automatically checks for valid subscriptions on restricted posts/pages, redirecting users without active subscriptions to the specified page.
- Customize Styling: Style subscription tables and meta boxes using WooCommerce’s default CSS classes or by targeting
.woocommerce-table--subscriptions.
Requirements
- WordPress 5.0 or higher
- PHP 7.0 or higher
- WooCommerce 4.0 or higher
- (Optional) Polylang for multilingual support
- WooCommerce My Account page configured with the
shortcodeLogin




