Quick Start: WooCommerce
Get referral tracking running on your WooCommerce store in under 10 minutes. The Advocate Loop plugin handles everything — referral link detection, automatic discount application, and conversion tracking on order completion.
Prerequisites
- WordPress 5.8 or higher
- WooCommerce 6.0 or higher
- An Advocate Loop account (sign up here)
Step 1: Install the plugin
- In your WordPress admin, go to Plugins → Add New
- Search for “Advocate Loop” or upload the plugin ZIP file
- Click Install and then Activate
Step 2: Connect your brand
- Go to WooCommerce → Advocate Loop in your WordPress admin
- Enter your API Key and Brand ID from the Advocate Loop dashboard (Settings → API Keys)
- Click Save Changes
The plugin will verify the connection and show a green checkmark when connected.
Step 3: Configure your referral program
In the Advocate Loop dashboard at app.advocateloop.com:
- Go to Settings → Referral Program
- Set your customer discount — the discount referred customers receive (e.g., 15% off)
- Set your advocate reward — what advocates earn per successful referral (e.g., $10 store credit)
- Set your attribution window — how long a referral link stays valid (default: 7 days)
Step 4: Add the referral widget
The widget lets visitors claim their referral discount and lets customers sign up as advocates. Add it to any page:
Option A: Shortcode (recommended)
Add this shortcode to any page or post:
[advocateloop_widget]Option B: Auto-placement
In the plugin settings, enable “Auto-place widget” and select where it should appear (e.g., after product content, in the sidebar).
Step 5: Test it
-
Create a test advocate — In the Advocate Loop dashboard, go to Referrers and create a test referrer with your email. Note the referral code (e.g.,
V2AVMRDJ). -
Visit your store with the referral link — Open an incognito/private browser window and visit:
https://yourstore.com/?ref=V2AVMRDJ -
Check that the discount applies — Add a product to cart and go to checkout. The referral discount should be automatically applied as a coupon.
-
Complete a test order — Place the order. Check the Advocate Loop dashboard — you should see a new claim and conversion.
Plugin settings reference
| Setting | Description | Default |
|---|---|---|
| API Key | Your Advocate Loop API key | Required |
| Brand ID | Your brand’s UUID | Required |
| Cookie Duration | How long the referral cookie persists (days) | 30 |
| Debug Mode | Show detailed logging in browser console | Off |
| WooCommerce Integration | Enable automatic discount and conversion tracking | On |
| Auto-place Widget | Automatically add the referral widget to pages | Off |
Troubleshooting
Discount not applying at checkout
- Open browser console and check for
[AdvocateLoop]log messages - Confirm your discount settings are configured in the Advocate Loop dashboard
- Verify the visitor arrived through a referral link (
?ref=CODEin URL)
Conversion not recording
- Check the thank-you page console for tracking confirmation
- Verify your API key is correct in the plugin settings
- Contact support with the order ID and your brand ID if the issue persists
Widget not showing
- Ensure the shortcode
[advocateloop_widget]is on the page - Check for JavaScript errors in the browser console
- Verify the plugin is activated
Enable Debug Mode in the plugin settings to see detailed API call logging in the browser console for troubleshooting.