Embedding countdowns on web pages
Add live timers to your site while ensuring recipient continuity and testing outside your editor.
2 min read
Screenshots use fictional demo data. Your controls may differ by plan, role, or environment. Use the values generated in your own workspace.
Retrieving embed codes
- 1Save and publish your campaign, then access the website publishing option.
- 2Copy the generated embed code, which contains the correct campaign references and script URL.
- 3Paste this code into a Custom HTML or code block that supports script execution. Place it where the timer should appear, then save and publish your website.
- 4Load the live website outside of the builder's editor to test mobile responsiveness, the live state, and the expired state.
Purpose of the public page
Website builder canvases may disable scripts or utilize restricted iframe environments. A working editor preview does not guarantee the page will function live, and conversely, a blank preview does not always indicate a broken embed.
If your builder automatically strips script tags, use its designated code-injection feature or choose a different countdown delivery method. Do not attempt to paste JavaScript into a standard text block.
Maintaining cross-channel consistency
When a recipient arrives from an email, ensure their opaque vid value and any required deadline fields from the original link are preserved. Removing these parameters may cause the website to assign an anonymous visitor window instead.
The public embed is not intended to hold an API key. Use the campaign’s public references, store administrative credentials on your own server, and never expose private customer data in URLs.
Addressing site security and caching
Content Security Policies, consent managers, browser extensions, or mixed-content blocking may interfere with the countdown script or its network requests. Keep your site and resources on HTTPS and ensure your website administrator permits the required countdown origin.
After saving changes, verify the update on a fresh public page load. Page builders often cache old markup even after the campaign is updated. Avoid changing the campaign deadline repeatedly to debug script-loading issues.