Skip to main content
The product page widget renders instalment messaging next to the price (e.g. “or as low as £200.00 over 3 months interest-free”), along with a built-in “How it works” explainer modal, all from a single script tag with no API call or signature required.
If your store runs WooCommerce, Shopify, or Magento with the official Float plugin, instalment messaging is already included, so you don’t need to add it yourself. This page is for custom API integrations.

Add the widget

Place a script tag wherever the messaging should render, typically directly below the price:
The script injects its own markup (logo, instalment breakdown, and a “How it works” link) at its own position in the DOM. There’s no container element or JS SDK to set up.
Two product cards, each showing the Float logo and 'Or as low as £200.00 over 3 months interest-free' and '£325.00 over 4 months' respectively

Two widgets on one page, each calculating from its own price and term.

Parameters

Which terms are shown

Precedence is instalments, then public_id, then the default of 3:
With instalments=3,6 the line reads “Or as low as £100.00 over 6 months interest-free” and the modal’s worked example offers both terms. With public_id, Float looks up the term rule covering the price (your rules can differ by basket size) and uses its terms; the lookup is cached on Float’s CDN, so it adds no load to your page. With public_id the widget never guesses: if Float has no terms for the merchant, no rule covers the price, or the terms cannot be fetched (for example a Content-Security-Policy that blocks widgets.float.co.za), it renders nothing rather than advertise a term you may not offer. Pass instalments if you want the widget to show regardless. The modal splits the example exactly as checkout splits a real plan: equal instalments with any rounding remainder on the last one. An embed with neither parameter still renders: the line advertises 3 months, and the modal offers a generic set of terms with a note that options may differ by retailer. See Widget & modal implementation for that fallback, the sandbox and production hosts, and how to open the modal yourself.

Keep the price in sync

If the price can change without a page reload (a variant picker, a quantity stepper, a discount code), call floatUpdate on the rendered element:
A widget that rendered nothing (zero price, or no terms for the price) has no .float-w element, so check for it before calling. With several widgets on the page, scope the lookup to the product you’re updating:
Re-inserting a fresh <script> element also works, but floatUpdate avoids the re-fetch. Changing the src attribute on an existing script tag does nothing.

Handle missing or zero price

Don’t render the widget with price=0 or blank. The script renders nothing at all in that case, rather than advertising £0.00. Suppress the widget for unpriced or out-of-stock items.

Multiple widgets on one page

Category, search, and “related products” pages can safely render as many widgets as they like. Each one is scoped to its own instance and calculates from its own price and instalments.

What’s included

The “How it works” link opens a modal that’s already wired up; you don’t need to link to the explainer page yourself or build a lightbox. The modal reflects the actual product price, so a £600 product shows a £600 worked example, and it uses the UK copy and card requirements.
The How it works modal with the Powered by Float badge, UK copy, a picker offering 2, 3 and 4 instalments with 4 selected, and a schedule splitting £600 into four instalments of £150 with £450 held on the card today

The explainer modal for a £600 product embedded with instalments=2,3,4.

Everything is served as static files from a CDN, and the logo, styles, and fonts are inlined into the script, so rendering the widget is a single request. Nothing further is fetched until a shopper opens the modal. It only renders correctly from a real page served over HTTP(S); it won’t work from a local static file preview.
No, this widget is purely on-page merchandising. You still create a checkout and redirect the shopper as described in Accepting payments once they choose Float.
The first instalment is charged at the time of purchase and the remainder of the purchase amount is reserved on the card, with the remaining instalments charged on the same day each month. If your account is configured differently, render your own messaging from your merchant config instead.
The script is about 13 KB gzipped, served from a CDN with a long cache lifetime, and makes no API calls. The explainer modal is only fetched if a shopper actually opens it.