Custom Affiliate Slugs - Setup

Note: This article relates to the Custom Affiliate Slugs pro add-on.

Installation and setup

  1. Download the Custom Affiliate Slugs pro add-on from your account page
  2. Install and activate the add-on just as you did when you installed AffiliateWP
  3. Make sure you've updated AffiliateWP to the latest version (v1.7.18 or newer is required)
  4. Go to Affiliates → Settings and click the Custom Affiliate Slugs tab (see image below) to configure the add-on

Admin options

Allow Custom Affiliate Slugs

Enable this option if you'd like all affiliates to be able to add a custom slug. Leave this option unchecked if you only want to enable custom slugs on a per-affiliate level (see below).

Show Custom Slug

If your Default Referral Format in AffiliateWP's General settings tab is set to ID or Username you can enable this option and the affiliate's custom slug (if they have one) will be shown on the Affiliate URLs tab of the Affiliate Area, (however the URL generator will continue to work only for the ID or Username). If you set the Default Referral Format to Custom Affiliate Slug, the affiliate ID or Username will not be shown, the affiliate's custom slug will be shown in place of their ID and username, plus they will be able to use the URL generator to generate a referral URL with their slug in it.

Auto-create Custom Slugs

Enable this option if you'd like custom slugs to be automatically generated for your affiliates when:

  1. An affiliate registers via the affiliate registration form
  2. The Auto Register New Users option is enabled from Affiliates → Settings → Misc and a user is automatically registered as an affiliate
  3. An affiliate is added manually via the Affiliates → Affiliates → Add New screen
When this option is enabled an  Auto-create Slug Settings section will appear with the following options:
Slug Preview

This will show the admin an example of what an automatically generated slug could look like. This preview will dynamically update as you alter the slug type and slug length as mentioned below.

Slug Type

Choose between an alphanumeric (letters and numbers) or alphabetic slug (letters only). Note: Custom slugs can be all lowercase, all uppercase, or sentence case (a mix of both lowercase and uppercase) letters.
Slug Length

Set the length of a newly generated slug (the maximum length is 60 characters as per WordPress' default username standards).

Setting the Default Referral Format

If you've been using AffiliateWP for some time, we've added some settings to make Custom Affiliate Slugs more seamless without disrupting your affiliates' experience.

If your default referral format is set to ID or Username, this is what affiliates will be used to seeing in the Affiliate URLs tab of the Affiliate Area. By enabling the Show Custom Slug option in Affiliates → Settings → Custom Affiliate Slugs, the affiliate will still see their ID or username as normal, however they will also now see their custom slug, and a custom slug URL they can use above their ID or username. If they use the URL Generator, this will continue to generate a URL for the affiliate using their ID or username (depending on which default referral format you have set).

When you install and activate Custom Affiliate Slugs, a new Custom Affiliate Slug option will also appear in the Default Referral Format dropdown in the Affiliates → Settings → General tab. This allows you to show an affiliate their referral URL with their custom slug, rather than the ID or username. The affiliate will also be able to generate a referral URL using the generator with their custom slug (their ID or username will not be visible).

  1. Go to Affiliates → Settings. You'll then be on the General tab of the settings
  2. Scroll down to the Default Referral Format dropdown menu and select Custom Affiliate Slug
  3. Click the Save Changes button at the bottom of the page

Once this option is enabled, the URL shown in the  Affiliate URLs tab of the Affiliate Area will include the affiliate's custom slug. If an affiliate does not have a custom slug, or they remove it themselves, it will fallback to showing their username as the default referral format.

Per-affiliate custom slugs

An admin can allow custom slugs on a per-affiliate basis.

  1. Go to the AffiliatesAffiliates screen 
  2. Click the Edit link in the Actions column for the affiliate you wish to enable custom slugs for
  3. Enable the Allow Custom Slug checkbox option
  4. Click the Update Affiliate button

Changing an existing affiliate's slug as an admin

An admin can change an affiliate's custom slug:
  1. Go to the Affiliates → Affiliates screen
  2. Click the Edit link in the Actions column for the affiliate you wish to change the custom slug for
  3. Find the Custom Slug field and enter a new slug for the affiliate (or remove it)
  4. Enable the confirmation checkbox that will appear after validation passes
  5. Click the Update Affiliate button

Adding a custom slug while adding a new affiliate

An admin can add a custom slug while they are adding a new affiliate:
  1. Go to the Affiliates → Affiliates screen
  2. Click the Add New button
  3. Select the affiliate from the User field, and complete the other fields
  4. Enter a custom slug in the Custom Slug field
  5. Click the Add Affiliate button

If no custom slug is entered for the affiliate, and  Auto-create Custom Slugs is enabled from the admin settings, a randomly generated custom slug will be given to the affiliate.

Exporting a .CSV file of affiliates and their custom slugs

An admin can export a .CSV file that contains the current custom slug for each affiliate.
  1. Go to Affiliates → Tools and make sure you're on the Export/Import tab
  2. In the Export Affiliates section, select a status and then click the Export button
  3. At the download prompt click OK (or similar) to download the .CSV file to your computer
  4. Inside the .CSV file, there will be a new column titled Custom Slug.

(Note: if the Allow Custom Affiliate Slugs option is enabled or a per-affiliate custom slug is enabled, affiliates can change their slug at any time.)

Adding a custom slug (as an affiliate)

  1. Go to the Affiliate Area's Settings tab.
  2. Enter a slug in the Custom Affiliate Slug input field.
  3. Enter the slug one more time to confirm in the confirmation field that appears.
  4. Click the Save Profile Settings button.

Here's the Custom Affiliate Slug input field in the Affiliate Area:

When an affiliate has entered a custom slug they will be prompted to confirm it by re-entering the custom slug once more:

Note: Custom Affiliate Slugs requires AffiliateWP version 1.7.18 or newer, and a Professional or Ultimate license. Fallback tracking (enabled from Affiliates → Settings → Misc) is not currently supported.