Websites and builders

Framer
Add the Plandalf script to your Framer site settings once, then drop an Embed component wherever you want a checkout button, an inline checkout or a deadline timer.
Framer runs custom code only on a paid site plan, and only on the published site, not in the canvas or preview.
Add the script
These are the install steps for Framer. Copy the script from your checkout's Share screen (pick HTML) so it holds your own address.
Install the SDK
Site Settings → Custom Code → End of <body>. Paste the script tag.
<script async src="https://YOUR-ORG.plandalf.dev/js/plandalf-sdk.js"></script>Add the trigger button
Insert an Embed component where you want the element. Paste the HTML.
<button data-plandalf-present="YOUR-CHECKOUT">Buy Now</button>Make the first open instant (optional)
Paste this under the SDK script tag on the pages that hold the trigger. It fetches the checkout UI (about 1.2 MB) in the background while the page sits idle, so the click only pays for creating the session. Leave it off pages with no checkout: visitors download it whether or not they buy. In a React app, call sdk.preload('checkout') from the ready callback in an effect instead.
<script> // Optional: fetch the checkout UI while the page is idle, so the first click opens at once. window.plandalf = window.plandalf || function () { (window.plandalf.q = window.plandalf.q || []).push(arguments); }; plandalf('ready', (sdk) => sdk.preload('checkout')); </script>
In Framer, open Site Settings → General, scroll to Custom Code and paste the script into End of <body> tag. Then click Publish.
Open a checkout from a button
Insert an Embed component where the button should go, set it to HTML and paste:
<button data-plandalf-present="YOUR-CHECKOUT">Buy Now</button>
Style the button with inline CSS or a class in your custom code. Framer adds HTML embeds to the published page after it loads, which is fine: the script watches for elements added later. More options are in Buy buttons.
Show a checkout on the page
Insert an Embed component, set it to HTML and paste:
<div data-plandalf-mount="YOUR-CHECKOUT" style="min-height: 480px"></div>
Size the Embed component to fit the checkout, or set its height to fit content.
Show a deadline timer
In an Embed component, paste an empty element with your deadline timer's slug. The script draws the live countdown inside it. To charge the deadline timer's current price, add data-plandalf-apply-promo with the same slug to your buy button.
<div data-plandalf-promo="YOUR-PROMO"></div>
<button data-plandalf-present="YOUR-CHECKOUT" data-plandalf-apply-promo="YOUR-PROMO">Buy Now</button>
See Countdowns.
Check it's working
Open the published site
Use a private window. In the browser console, type
plandalf: you should see a function.undefinedmeans the script isn't on the page.Click your button
The checkout opens over the page.
Make a test purchase
Add your Framer address, such as
your-site.framer.website, in Plandalf under Settings → Advanced → Test domains. Checkouts there use Stripe test cards while your custom domain stays live. See Test mode.
If it isn't working
- Publish again after you change custom code, and check the plan includes custom code.
- The canvas and preview never run the script. Test the published URL.
- Add
data-debug="true"to the script tag and the console logs each step the script takes.
See Troubleshooting.