Survey widget installation

Use Featurebase surveys to collect feedback from your users and measure customer satisfaction.

Written By Robi Rohumaa

Last updated 6 days ago

πŸ‘¨β€πŸ’» You'll need to write custom code for the setup process. If you're uncomfortable with this, share this guide with a technical team member who can assist.

Featurebase's survey's.

Step 1 β€” Install the Featurebase SDK

Every widget β€” including Survey widget β€” inherits its appId and the signed-in user from a single universal Featurebase install at your app root. Do that first, then come back here for the widget-specific mount call.

πŸ‘‰ Follow Installation overview (it takes about 2 minutes). Your appId lives in Settings β†’ Developers β†’ Installation.

πŸ‘€ Logged-in product? Use a server-signed featurebaseJwt on the universal boot so feedback, responses, and read state are attributed to the right person. See Identifying users & syncing data.


Step 2 β€” Mount the Survey widget

Installing

The survey widget can be installed using our JavaScript SDK.

Example
// Inside <FeaturebaseProvider>, anywhere in your tree. 'use client'; import { useSurveyWidget } from 'featurebase-js/react'; export function SurveyHost() { useSurveyWidget({ placement: 'bottom-right', theme: 'light', locale: 'en', }); return null; }

The SDK loader <script> is already in your page from Installation overview β€” this tab shows only the widget-specific call you add alongside it.

Triggering the survey

After the widget is installed, each survey will trigger automatically based on the settings you have configured in the Featurebase dashboard.