Custom site
Attribute sales to creators on Custom site — Any site you control the HTML of. One script tag and one call.
Yonto attributes sales to the individual creator who drove them. On Custom site that works several ways, and the honest summary is that browser pixel does most of the work:
Setting it up#
Every campaign has its own tracking code. The snippets below use YOUR_TRACKING_CODE as a placeholder — copy the real ones from the campaign's Setup screen, which fills them in for you.
Conversions are reported from: Wherever you know the order succeeded.
- 1Add the pixel to every pageIt must be on the landing page as well as the confirmation page — the landing page is where the click is captured, the confirmation page is where it is spent.html
<script async src="https://yontosales.com/p.js" data-proof="YOUR_TRACKING_CODE"></script> - 2Fire the conversion on successCall proof() once the order exists and you know its id and total. Safe to call for any visitor: for one nobody referred it does nothing.html
<script> // On your order-confirmation page, once the order is known. // Both fields are REQUIRED for a sale campaign. proof('conversion', { value: 49.90, // the order total, as a number id: 'ORDER-1234', // your order id — this is what prevents double counting currency: 'GBP' // what the shopper actually paid in }); </script>
value and id are both required. The order id is what makes a retry or a refreshed confirmation page idempotent instead of a second sale. A call missing either is rejected — see the Conversion endpoint reference.What this can and cannot see#
Attribution is never complete, on any platform. You are about to pay a creator on the strength of these numbers, so here is exactly what is behind them on Custom site.
- Orders completed in the same browser that clicked the link, within 30 days.
- Orders that used the creator's discount code, whatever the shopper's cookie settings.
- Shoppers who refuse tracking cookies — the click is never linked to the sale.
- Purchases made on a different device from the click.
- Anyone running an ad blocker that blocks our script.
- Sales where the shopper cleared their browser data between clicking and buying.
- Refunds, unless you report them yourself.
This is why every figure Yonto reports is described as a confident floor rather than a total. The sales in the right-hand column happened; we simply cannot prove the creator caused them, and we would rather undercount than invent.
Making it more accurate#
- Ask the creator to lead with the discount code. It is the only method that survives a shopper refusing cookies, and it converts better anyway.
- Report from your backend instead of the browser. The server-side API sees orders that no browser-based method can.
- Report refunds. Custom site does not tell us when you refund an order, so a refunded sale stays counted unless you reverse it yourself.
- Use one discount code per campaign. Codes are matched before click ids, and a code shared across campaigns resolves to whichever matches first.