Floating feedback
A React launcher for written reports, viewport screenshots, annotations and picked elements. It does not display the public feedback board.
Install
Create an organization API key in Reflet and use its public fb_pub_ value. Never put an fb_sec_ key in browser code. The CLI can install the SDK and mount the launcher:
npx reflet-cli initFor supported frameworks, flags and setup diagnostics, see the CLI guide.
Mount the component
npm install reflet-sdkMount once in your app shell. The feedback entry is a client boundary, so a Next.js layout can stay a Server Component. Replace the placeholder key, then open the Feedback button.
// app/layout.tsx in Next.js
import { RefletFeedback } from "reflet-sdk/feedback";
import type { ReactNode } from "react";
export default function RootLayout({ children }: { children: ReactNode }) {
return (
<html lang="en">
<body>
{children}
<RefletFeedback publicKey="fb_pub_xxx" />
</body>
</html>
);
}For Vite, render the same component beside your app. Public keys can be literal values or public environment variables. No RefletProvider is required.
Report contents
- The first nonempty line of the message becomes the title, capped at 100 characters. An anonymous visitor can add an email or send without one.
- Screenshots render the DOM without a screen-sharing prompt. Reporters can add captures and annotate with pen, arrow, rectangle, text, spotlight, highlight or blur.
- Picking an element attaches its selector, redacted markup, bounds and available React component/source information. Production builds may omit source locations.
- Page context includes the URL, title, browser, OS, device, viewport, locale, timezone, console events and your metadata.
Props and custom trigger
"use client";
import { RefletFeedback } from "reflet-sdk/feedback";
export function Feedback() {
return (
<RefletFeedback
publicKey="fb_pub_xxx"
captureOnOpen={false}
captureConsole={false}
metadata={{ release: "2026.10" }}
renderTrigger={({ ref, onClick }) => (
<button ref={ref} onClick={onClick} type="button">
Report a problem
</button>
)}
/>
);
}Identify a user
Pass user to attribute reports and skip the email prompt. Browser-provided identity is not proof of who signed in. For verified identity, generate userToken on your server from the authenticated session; see user signing. Direct props override provider values.
Development tools
In development, RefletFeedback can load a toolbar for element notes, source lookup, the page's feedback and sessions. Development tools are guarded by NODE_ENV. Source and account actions also need a server integration; mounting the widget alone does not install it.
Follow the devtools setup for Next.js or Vite. Keep its server route on a trusted local development server: it can read source files and perform account actions.
Deployed team access
For team access on a deployed web app, keep teamTools enabled and open a page with ?reflet-team. Sign in to Reflet and approve the app. The activation makes the sign-in UI available; organization membership is checked by the server, not by the URL parameter or your app's user prop.
- Add the app's exact origin to the public key's Allowed domains. A key with no allowed origins cannot authorize deployed team access.
- Team access uses your Reflet account, not your product's customer identity. A stored team connection can activate tools on later visits.
- Set teamTools=false to remove deployed team tools. enabled=false only controls the customer report UI.
For recording permissions, collection, storage and handoff, read sessions. Desktop hosts use the desktop integration rather than browser popup sign-in.
Privacy and failure handling
- Review what your pages expose before enabling capture. Both original and annotated screenshots are uploaded. The blur tool changes the annotated image, not the stored original. Remove a sensitive capture instead of relying on blur.
- data-reflet-redact scrubs picked-element markup. It does not exclude that element from ordinary feedback screenshots. Automatic text filters are not a guarantee that all personal data or secrets are removed.
- URL fragments are dropped and credential-shaped query parameters are masked. Console strings are filtered, but your metadata and report text need your own data policy.
- Report context is excluded from public API projections. Written feedback and contact details entered into its description may still be visible on a public board. Do not treat a customer report as an internal team note.
- Cross-origin images, iframes and canvas content may be missing from DOM captures. A failed capture can be removed so the report can be sent without it.
- Images upload before the report is created. An upload failure leaves the draft for retry. If attaching uploaded images fails after creation, use Retry attachments; it does not create another report.
- The panel uses a shadow root. Configure labels, colors and a custom trigger through props rather than host-page CSS. Test keyboard focus, your chosen shortcut and zoom in the host app.
For API authentication, rate limits and error responses, see the API reference.