sfmc // AMPscriptPRODUCTION

Tracked Dynamic URL

Build a dynamic URL and preserve Marketing Cloud click tracking with RedirectTo().

ampscriptredirecttoutmtracking
Context Pack →Open Workspace →
Trust & provenancePRODUCTION
Evidence tierPRODUCTIONOfficial sources0Other sources0Last verifiedNot recorded

Evidence tier describes my hands-on relationship with the content. Official sources describe platform contracts/documentation. Production observations should not automatically be treated as official limits.

%%[
VAR @baseUrl, @campaign, @finalUrl
SET @baseUrl = 'https://example.com/offer'
SET @campaign = AttributeValue('CampaignName')
SET @finalUrl = Concat(@baseUrl,'?utm_source=sfmc&utm_medium=email&utm_campaign=',@campaign)
]%%
<a href="%%=RedirectTo(@finalUrl)=%%" alias="Primary_CTA">Open offer</a>
Operational notes

Keep dynamic link construction separate from the HTML attribute for readability.