How to add your Affiliate link to UpdraftPlus

UpdraftPlus now supports adding your own Affiliate link to UpdraftPlus to improve your commission. If you bundle an installation of UpdraftPlus in some way (you are not otherwise eligible) then to take advantage of this is easy.

All you need to do is bundle the latest version of UpdraftPlus with your WordPress installation and include a file inside the mu-plugins folder.

This file should hook into UpdraftPlus and replaces all links with your Affiliate link.

An example of this file would be:

//Enter your Affiliate ID here by replacing 1234 with your Affiliate ID
define("UPDRAFT_AFFILIATE_ID", "1234");

add_filter('updraftplus_com_link', 'updraftplus_affiliate_link_replace');

function updraftplus_affiliate_link_replace($url){
$url = $url . "?afref=".UPDRAFT_AFFILIATE_ID;
return $url;