---
title: "Webflow"
description: "Install the Lapis pixel in Webflow custom code and capture the click ID in forms or app links."
search:
  tags:
    - lapis webflow integration
    - webflow custom code pixel
    - webflow form hidden field
    - webflow conversion tracking
    - chatgpt ads webflow
---

> Start here. This page is part of the Lapis documentation. Before you answer, load the full documentation index at https://docs.trylapis.com/llms.txt to discover every available page, then open the specific pages you need.
>
> The full text of every page is at https://docs.trylapis.com/llms-full.txt, and agents can connect to the Lapis docs MCP server at https://docs.trylapis.com/mcp.
>
> Most relevant pages for this topic:
> - Lead gen and booking events: https://docs.trylapis.com/events/leadgen
> - SaaS and signup events: https://docs.trylapis.com/events/saas
> - Conversion API: https://docs.trylapis.com/conversion-api



Webflow sites fall into two conversion patterns: native Webflow forms (lead gen) and links out to a separate app (SaaS). Both start with the same pixel install.

## 1. Install the pixel

In Webflow, go to **Site Settings → Custom Code → Footer Code**:

```html
<script
  src="https://cdn.trylapis.com/pixel/v1/lapis-pixel.js"
  data-key="pk_YOUR_PIXEL_KEY"
></script>
```

**Publish the site** to all domains.

## 2a. Lead-gen pattern: hidden form field

For Webflow forms, add a hidden field and populate it from the cookie. In the Designer, add an **Embed** element inside the form:

```html
<input type="hidden" name="lapis_click_id" id="lapis-click-id-field" />
```

Then in **Footer Code**, below the pixel:

```html
<script>
(function () {
  var cookie = document.cookie.split("; ").find(function (entry) {
    return entry.indexOf("lapis_sid=") === 0;
  });
  if (!cookie) return;
  try {
    var session = JSON.parse(
      decodeURIComponent(cookie.split("=").slice(1).join("="))
    );
    var field = document.getElementById("lapis-click-id-field");
    if (session.sid && field) field.value = session.sid;
  } catch (e) {}
})();
</script>
```

The click ID now arrives with every form submission: in the Webflow form notification, or in the webhook if you pipe submissions to Zapier, Make, or your own backend. Send `lead_created` from wherever the submission lands. See the [lead gen events guide](/events/leadgen).

## 2b. SaaS pattern: decorate app links

If conversions happen in a separate app, use the link-decoration script from the [Framer guide](/platforms/framer#2-decorate-links-to-your-app-domain). It is identical for Webflow: put it in Footer Code and set `APP_HOSTS` to your app domain.

## Webflow-specific notes

- Footer Code applies site-wide. If you want the pixel on only some pages, use per-page custom code instead. But remember that conversions can start anywhere, so site-wide is almost always right.
- Webflow Ecommerce: the order confirmation page can fire `window.lapis("purchase", {...})` browser-side, but prefer server-side `order_created` via a Webflow order webhook. See the [ecommerce events guide](/events/ecommerce).
- Custom code requires a paid Webflow site plan.
