Is there a way to set the 'unsubscribe' link in an email to point to a page on the customer's website than Exact Target's profile center? On this web page, the idea is to determine the user's email address/subscriberkey through some query string parameter, fetch the lists that the user is subscribed to (I got this part using SOAP API), have him select which ones he wants to unsubscribe from and click the submit button to unsubscribe (I got this part also through the SOAP API). The part where I need help is how to change the unsubscribe link in the emails and how to add the emailaddress in the query string? Or is there a way to decode the query string parameter qs='xxxxxxxxxx' which gets included by default, and determine the user from that? Any help will be greatly appreciated.

Thank you.


1 Answer 1


There are several things you can do:

First. Unsubscribe link is a mandatory link. You cannot eliminate it but you can hide it. This is one of the options:

<span style="display:none;"><a href="%%unsub_center_url%%"></a></span>

Second Use the subscriber ID and email address in the email template you generate. You can use them in the AMPscript part of the email html. You can use them to build a URL to the new page.

%%[SET @clientkey = [_subscriberkey] ]%%
%%[SET @clientemail = [emailaddr] ]%%
%%[SET @clientkeyencoded = URLencode(@clientkey,1,1) ]%%
%%[SET @clientemailencoded = URLencode(@clientemail,1,1) ]%%
%%[SET @URLunsubscribe = Concat("www.something.com/?firstparameter=",@clientkeyencoded,"&secondparameter="@clientemailencoded")

Once you have built the URL you can use it like this in the HTML of the email template. href="%%=v(@URLunsubscribe)=%%

It is more than advisable to encrypt the parameters in the URL, you should not be comfortable having sensitive or personal data in the URL. You have some encrypt/decrypt functions in AMPscript but you could also use Javascript.

  • The unsubscribe link check can be disabled by ET support. Commented Jul 31, 2014 at 10:56
  • Also if you use href="%%=redirectto(@URLunsubscribe)=%% instead of href="%%=v(@URLunsubscribe)=%%, cicks on this URL will get tracked. Commented Jul 31, 2014 at 11:00
  • @Dr.Xavier Thank you! With some tweaks to this code, I was able to create a custom link. Commented Aug 5, 2014 at 4:15
  • @AdamSpriggs I will surely look into your suggestions. Thank you! Commented Aug 5, 2014 at 4:15
  • On a kind of unrelated note, not sure why edits on this site have to be atleast 6 characters. I only wanted to change "Contact" to "Concat", but had to tweak some more letters/spaces just to satisfy the criteria for edits :) Commented Aug 5, 2014 at 4:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .