> ## Documentation Index
> Fetch the complete documentation index at: https://docs.gleap.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Surveys

> Surveys 2.0: card and full-screen surveys with logic, partial responses, a survey page on your domain, personal links and the first question inside emails.

A Gleap survey is one definition — questions, logic and endings — that runs everywhere you reach people: in your web and mobile apps, on a survey page on your own domain, through links, inside emails and in conversations. Every answer is saved as it is given, so you see where people drop off and keep the answers of people who stop halfway.

The same definition is used by the dashboard editor, the [REST API](/documentation/surveys/rest-api), the [Gleap MCP server](/documentation/surveys/mcp) and Kai. Its format is documented in [Survey definition](/documentation/surveys/definition).

## Formats

| Format | Value | Looks like | On phones |
| - | - | - | - |
| Card | `card` | A compact card in the corner of your app with a sender row and a thin progress bar — one question at a time, answers save instantly. | Bottom sheet |
| Full screen | `full` | Typeform-style: one large question per screen, keyboard shortcuts (letters pick choices, digits pick scores, Enter continues), progress and up/down navigation. | Full screen |
| Page | `page` | The survey fills a container, used by the [survey page](#survey-page) and embeds. Only set by `showSurvey` options. | Fills the page |

<Note>
  **Legacy format names are deprecated aliases.** `survey` means `card`, and `survey_full` (and `survey_web`) mean `full`. They keep working in every SDK — the native SDKs still take `showSurvey(id, format)` with `SURVEY` / `SURVEY_FULL` — but new code should use `card` and `full`.
</Note>

## Question types

| Group | Types |
| - | - |
| Scales | `nps` (0–10), `csat` (1–5), `rating` (stars), `scale` (custom range) |
| Choices | `single`, `multi`, `yesno` |
| Inputs | `short`, `long`, `email`, `number`, `date` |
| Other | `upload` (files), `statement` (text only, e.g. an intro or a consent note) |

Each question has a stable **answer key** (for example `nps_score`). Webhooks, exports, the API and filters use these keys, so renaming a question never breaks an integration.

## Logic

Every question can jump based on the answer, Typeform/Intercom-style:

* **Per answer**: NPS 0–6 / 7–8 / 9–10, each choice, Yes / No — each goes to a later question or an ending.
* **All other cases go to**: where everyone else continues (by default the next question).
* **Conditions on the person**: contact properties (for example plan), [hidden fields](#hidden-fields) and the page URL.

Rules are checked top to bottom and the first match wins. Jumps only go forward, so a survey can't loop. Before you publish, Gleap checks that every question is reachable and every path ends in an ending.

A survey can have several **endings** (thank-you screens), each with its own text, an optional button, an optional redirect (survey page) and an optional contact tag.

## Ask Kai to edit

At the bottom of the outline, describe a change in your own words and press Enter (or press <kbd>I</kbd> anywhere in the editor to jump there). For example:

* "Add a follow-up for detractors asking what to fix"
* "Make it shorter"
* "Translate to German"
* "Turn Q3 into multiple choice with Speed, Price and Support"
* "Jump to the thank-you ending when they say no"

"This question" means the question you have selected. Kai edits the **draft** only: the change shows in the editor right away, the outline marks the new and edited steps, and a short card lists what changed with **Keep** and **Undo**. Nothing is published until a teammate publishes it.

* Existing questions keep their answer keys, and answer options Kai keeps keep their ids, so earlier responses, filters and webhooks are unaffected.
* A translation adds the language to every text; the language shows in the editor once it is one of your project's languages.
* If the result has logic problems (for example a question nobody reaches), the card says so and publishing stays blocked until they're fixed.
* Kai only edits the survey's questions, logic, wording, languages, design and settings. It doesn't publish, send or target a survey.

Ask Kai to edit is included in paid plans and doesn't use AI credits: it's tracked as AI editor usage (GPT-6 Luna) without being charged. Free has no AI features, so there it answers `402`.

## Partial responses

Answers are stored per question, not at the end. A response is:

| Status | Meaning |
| - | - |
| `in_progress` | The person is answering. |
| `completed` | The person reached an ending. |
| `partial` | No new answer for 30 minutes before reaching an ending. The answers given so far are kept and counted. |

Results show how many people saw, started and completed the survey, and how many reached and answered each question (drop-off).

## Versions

Edits are saved as a **draft**. **Publish changes** freezes the draft as the next version; respondents always see the published version, and every response remembers the version it answered. AI agents (the MCP server, Kai) only create and edit drafts — publishing needs a teammate.

## Sharing channels

### In the app

Show a survey with triggers (time on page, page visits, events) and audiences, exactly like other outbound messages, or from code with `showSurvey`:

```javascript theme={null}
Gleap.showSurvey("SURVEY_ID", { format: "full", fields: { plan: "pro" } });
```

See [JavaScript SDK → Surveys](/documentation/javascript/surveys). The native SDKs keep `showSurvey(id, format)`.

### Survey page

Every survey can have its own page on your help center domain:

```
https://help.yourcompany.com/s/<slug>
https://help.yourcompany.com/de/s/<slug>
```

The page uses your logo, brand colour and languages, unfurls with a preview of the first question when you paste the link, and is not indexed by search engines. Under **Share → Survey page** you choose who may answer (anyone with the link, or personal links only), one response per person, a closing date or response limit, and what happens after submit (show the ending or redirect).

URL parameters that match a hidden field's key are recorded with the response, for example `/s/onboarding?plan=pro&source=newsletter`.

### Links from before Surveys 2.0

Survey links shared before Surveys 2.0 (`https://forms.gleap.io/<id>`, in the US region `https://forms.us.gleap.ai/<id>`) keep working: they redirect to the survey's page. When an older survey is upgraded to Surveys 2.0 it gets a page open to anyone, at an address like `/s/feature-satisfaction-k3x9q2`. The page is switched on if the survey is live or has ever been answered; for drafts and surveys nobody answered it starts switched off, and their old links show "This survey is no longer available". Change the address or switch the page on or off under **Share → Survey page**; old links follow within an hour. The background of the old share page (image or colour) becomes the survey's background; its footer links and link colour are not carried over.

What the old link carried comes along: `?lang=de` opens the page in German, `customData` values whose keys match a [hidden field](#hidden-fields) are passed on, and links from survey email campaigns (`gleap-id` / `gleap-hash`) open as a [personal link](#personal-links) for that contact.

### Personal links

Personal links attach the response to a known contact without them signing in. Create them under **Share → Survey page → Personal links** (one link per contact, also as a CSV for your email tool). Each link carries a signed token:

```
https://help.yourcompany.com/s/onboarding?t=<personal token>
```

The token only says which contact a response belongs to; it never signs anyone in. With **Personal links only** the page refuses responses without a valid token, and **One response per person** applies per contact.

### Email (first question inline)

Send a survey with an email campaign and put the **first question inside the email**: the reader clicks a score or a choice in their inbox, lands on the survey page with that answer preselected and continues from the second question. Opening the link records nothing until the page has loaded, so mail scanners that follow links don't create answers. Campaigns support an audience, a send time, a reminder for people who haven't answered and a quiet period.

### Embed and more

Embed the survey inline in your site with `showSurvey(id, { format: "page", container })`, start it from a conversation, or print the page's QR code.

## Hidden fields

Hidden fields are values you pass in rather than ask: a plan, an order id, a campaign. Declare them in the survey (`fields`), then pass values with `showSurvey(id, { fields })`, URL parameters on the survey page, or personal links. They are stored with the response, can drive logic (`src: "field"`) and can be used in question text as `{{field.plan}}`.

## Results and AI insights

* **Summary**: shown, started, completed and partial counts, NPS with its distribution, drop-off by question and a card per question.
* **Analytics**: views, starts and submissions against the previous period, drop-off and time per question, devices, channels, sources and the best time to ask. See [Survey analytics](/documentation/surveys/analytics).
* **Insights**: Kai tags text answers with themes and sentiment when you open the results after new responses (the page shows "updating…" for a minute or two; without new responses nothing is recomputed), and shows drivers (how a theme moves NPS), segments (for example by plan) and spike alerts. Ask questions in plain language and get answers with cited responses. AI usage is billed as token usage.
* **Responses**: filter by status, score, theme or text, open a response to see the path someone took, and **Reach out** — start a conversation with that person, linked to their response.

Survey responses no longer create tickets in the inbox. Use [webhooks](/documentation/surveys/webhooks) to send responses to other tools.

## Plans

| | Free | Team, Pro and Enterprise |
| - | - | - |
| In-app surveys (card and full screen through the SDKs) | ✓ | ✓ |
| Responses you can see per survey | The first 10 | All |
| Survey page, email, website embed, personal links and QR codes | | ✓ |
| AI insights, Ask about results, Ask Kai to edit and AI translations | | ✓ |
| Survey automations (workflows) and integrations | | ✓ |
| "Powered by Gleap" on the survey | Shown | Removed |

On Free, every response is stored. Results, exports, search, the API and the MCP tools show the first 10 responses a survey received (deleting one does not bring another into view). Upgrading shows every response at once. A response beyond the first 10 answers `404` on Free, and list responses carry `limited: { limit, visible, total }`.

What Free doesn't include (the share channels and the AI features) answers `402` with `details.type: "plan_required"` and `details.requiredPlan: "team"`.

A survey from before Surveys 2.0 (a legacy survey that hasn't been upgraded) can't be created or set live on Free: the API answers `402` ("Surveys from before Surveys 2.0 are available on the Team plan. Create a new survey, or upgrade this one to Surveys 2.0."). Its answers would be tickets, outside the first-10 rule. Open it in the dashboard and press **Upgrade** to turn it into a Surveys 2.0 survey first.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.