Is it possible to implement a Klaviyo campaign on a button?
While Klaviyo's built-in button options don't allow for campaigns, you can custom code a button that include a campaign using HTML.
The following code block shows an example of using HTML to custom code a button for cancelled subscribers to click and reactivate their subscription at a discounted price
<p>Come back to us and get a discount code cause you deserve it.<br />
{% with activeSubs=person.rc_all_subscriptions|dictfilter:"status == CANCELLED" %}
{% with prepaidSubs=activeSubs|dictfilter:"is_prepaid == 0" %}
{% for sub in prepaidSubs|slice:"0:2" %}
<a href="https://wilsons-testing-store-sci.myshopify.com/tools/recurring/quick_actions/{{ person.rc_customer_hash }}/process?action=reactivate&action=apply_discount&subscription_id={{ sub.subscription_id }}&discount_code=<DISCOUNTCODE>"> <button> Click here to reactivate</button></a>
your subscription for {{ sub.product_title }}
<br />
{% endfor %}
{% endwith %}
{% endwith %}
</p>
Adjust the campaign link and language to best fit your needs, and customize the appearance of the button with CSS to seamlessly integrate with your notification's branding.
It is recommended you work with a Klaviyo Recharge partner when implementing customizations.