Create an Affiliate Program with Paid Memberships Pro
Step-by-step guide to integrating affiliate tracking with your Paid Memberships Pro site
Paid Memberships Pro is a powerful WordPress membership plugin that helps you create and manage membership sites, online courses, and subscription businesses. If you're using Paid Memberships Pro and want to grow through affiliate marketing, AffiliateBase provides seamless integration.
This comprehensive guide will walk you through everything you need to know about setting up an affiliate program with Paid Memberships Pro, from plugin installation to tracking membership sign-ups, renewals, and subscription changes.
Whether you're selling premium content, online courses, or subscription memberships, an affiliate program can help you acquire new members while rewarding your partners for successful referrals.
Follow these steps to integrate AffiliateBase with Paid Memberships Pro:
Install AffiliateBase WordPress Plugin
Connect Your AffiliateBase Account
Enable Paid Memberships Pro Integration
Configure Payment Gateway Webhooks
Set Up Commission Rules
Test the Integration
Custom Paid Memberships Pro Integration Example
If you prefer a custom integration, here's how to track Paid Memberships Pro transactions:
<?php
// Add to your theme's functions.php or custom plugin
// Track Paid Memberships Pro membership sign-ups
add_action('pmpro_after_checkout', 'affiliatebase_track_pmp_signup', 10, 2);
function affiliatebase_track_pmp_signup($user_id, $morder) {
// Get affiliate ID from cookie or URL parameter
$affiliate_id = isset($_COOKIE['affiliate_id']) ? $_COOKIE['affiliate_id'] : null;
if ($affiliate_id && $morder->status === 'success') {
$api_key = get_option('affiliatebase_api_key');
$membership_level = pmpro_getMembershipLevelForUser($user_id);
wp_remote_post('https://api.affiliatebase.com/track-conversion', [
'headers' => [
'Content-Type' => 'application/json',
'Authorization' => 'Bearer ' . $api_key,
],
'body' => json_encode([
'affiliateId' => $affiliate_id,
'type' => 'membership_signup',
'amount' => $morder->total,
'currency' => $morder->currency,
'customerId' => $user_id,
'subscriptionId' => $morder->subscription_transaction_id,
'metadata' => [
'membership_level_id' => $membership_level->id,
'membership_level_name' => $membership_level->name,
'order_id' => $morder->id,
],
]),
]);
}
}
// Track subscription renewals
add_action('pmpro_subscription_payment_completed', 'affiliatebase_track_pmp_renewal', 10, 2);
function affiliatebase_track_pmp_renewal($subscription, $order) {
// Get original affiliate from subscription metadata
$affiliate_id = get_user_meta($subscription->user_id, 'affiliatebase_affiliate_id', true);
if ($affiliate_id && $order->status === 'success') {
// Track renewal conversion
// Similar code as above but with type: 'membership_renewal'
}
}
Why Use AffiliateBase with Paid Memberships Pro?
AffiliateBase is the perfect solution for Paid Memberships Pro site owners who want powerful affiliate tracking.
Native PMP Integration
Built-in integration with Paid Memberships Pro hooks and events. Automatically tracks membership sign-ups, renewals, and subscription changes.
Multiple Payment Gateway Support
Works with Stripe, PayPal, and other payment gateways supported by Paid Memberships Pro. Tracks both one-time and recurring payments.
Subscription Lifecycle Tracking
Tracks subscription renewals, upgrades, downgrades, and cancellations. Ensures affiliates receive commissions for recurring revenue.
Multiple Membership Levels
Support for different commission rates based on membership tiers. Perfect for sites with multiple membership levels.
WordPress Plugin
Easy-to-use WordPress plugin with Paid Memberships Pro integration built-in. No coding required for basic setup.
Affiliate Dashboard
Give your affiliates a professional dashboard to track their performance, view commissions, and generate affiliate links.
Frequently Asked Questions
Does AffiliateBase work with Paid Memberships Pro? ▼
Yes! AffiliateBase has native integration with Paid Memberships Pro through our WordPress plugin. It automatically tracks membership sign-ups, renewals, and subscription changes.
How are subscription renewals tracked? ▼
AffiliateBase tracks Paid Memberships Pro subscription renewals automatically. When a member's subscription renews, the original affiliate receives commission for the renewal, ensuring they're rewarded for recurring revenue.
Does it work with Stripe and PayPal? ▼
Yes! AffiliateBase integrates with all payment gateways supported by Paid Memberships Pro, including Stripe, PayPal, and others. It tracks both one-time payments and recurring subscriptions.
Can I set different commission rates for different membership levels? ▼
Yes! You can configure different commission structures in AffiliateBase based on membership level or any other criteria. This gives you full control over your affiliate program.
Do I need to modify my Paid Memberships Pro checkout? ▼
No, the integration works automatically with Paid Memberships Pro's standard checkout flow. AffiliateBase captures affiliate IDs from cookies or URL parameters and tracks conversions when transactions complete.
What happens when a member upgrades or downgrades? ▼
AffiliateBase tracks membership changes and adjusts commissions accordingly. The original affiliate maintains attribution, and commissions are calculated based on the new membership level.
Related Platform Guides
Create an Affiliate Program with Restrict Content Pro
Complete guide to setting up an affiliate program with Restrict Content Pro. Track membership sign-ups, renewals, and upgrades using AffiliateBase.
Create an Affiliate Program with Next.js
Complete guide to setting up an affiliate program in Next.js. Step-by-step integration with code examples and best practices for Next.js developers.
Create an Affiliate Program with Nuxt
Complete guide to setting up an affiliate program in Nuxt. Step-by-step integration with Nuxt 3, server routes, and composables for Vue developers.
Create an Affiliate Program with WordPress
Complete guide to setting up an affiliate program in WordPress. Step-by-step integration with plugins, themes, and Stripe for WordPress SaaS and membership sites.
Create an Affiliate Program with Webflow
Complete guide to setting up an affiliate program in Webflow. Step-by-step integration with Webflow CMS, custom code, and forms for no-code developers.
Ready to Launch Your Paid Memberships Pro Affiliate Program?
Get started with AffiliateBase today and start growing your membership site through affiliate marketing.