Documentation for automated readers
A curated documentation index is available at: https://grafana.com/llms.txt
A complete documentation index is available at: https://grafana.com/llms-full.txt
These indexes can help with page discovery before fetching individual documents.
This page is also available in Markdown, which may be easier for automated readers and AI tools to parse than HTML. The Markdown version is available at https://grafana.com/docs/grafana-cloud/monitor-applications/frontend-observability/session-replay/troubleshoot.md, or by sending Accept: text/markdown to https://grafana.com/docs/grafana-cloud/monitor-applications/frontend-observability/session-replay/troubleshoot/. For broader documentation discovery, the curated index is available at https://grafana.com/llms.txt and the complete index is available at https://grafana.com/llms-full.txt.
Troubleshoot
Note
Session Replay is currently in private preview. Grafana Labs offers support on a best-effort basis, and breaking changes might occur prior to the feature being made generally available.
This page covers common Session Replay issues and how to fix them.
My Session Replay appears corrupted
Applications built with React, or with a framework that uses React under the hood such as Next.js, can initialize Faro more than once as components render. This can corrupt recordings.
To prevent this, initialize Faro only once by using the provider pattern.
Create a provider that initializes Faro a single time:
tsx// provider.tsx 'use client'; import { getWebInstrumentations, initializeFaro } from '@grafana/faro-web-sdk'; import { ReplayInstrumentation } from '@grafana/faro-instrumentation-replay'; import { useEffect, useRef } from 'react'; function FaroProvider({ children }: { children: React.ReactNode }) { const initializeOnce = useRef(false); useEffect(() => { if (!process.env.NEXT_PUBLIC_FARO_COLLECTOR_URL || initializeOnce.current) { return; } initializeOnce.current = true; initializeFaro({ url: process.env.NEXT_PUBLIC_FARO_COLLECTOR_URL, app: { name: 'my-app', version: '1.0.0', }, instrumentations: [...getWebInstrumentations(), new ReplayInstrumentation()], }); }, []); return <>{children}</>; } export default FaroProvider;Load the provider dynamically so that it only runs in the browser:
tsx// providerDynamic.tsx import dynamic from 'next/dynamic'; import { Fragment } from 'react'; const initFaroProvider = () => { if (!process.env.NEXT_PUBLIC_FARO_COLLECTOR_URL) { return Fragment; } return dynamic(() => import('./provider')); }; const DynamicFaroProvider = initFaroProvider(); export default DynamicFaroProvider;Wrap your application with the provider:
tsx// app-providers.tsx import DynamicFaroProvider from './providerDynamic'; export default function AppProviders({ children }: { children: React.ReactNode }) { return <DynamicFaroProvider>{children}</DynamicFaroProvider>; }
If recordings still don’t load correctly, verify that Session Replay is instrumented and sending data:
- Check that Session Replay is instrumented:
- Load a page that should be instrumented with Session Replay.
- In the browser console, run
window.faro.instrumentations.instrumentations.map(i => i.name)and confirm@grafana/faro-instrumentation-replayis in the returned list.
- Check that Session Replay is sending events to the collector:
- Inspect the network requests to the collector and confirm the payload contains Session Replay events.
My recording hasn’t appeared yet
After a session is recorded, it can take up to five minutes for the recording to appear on the Sessions page in Frontend Observability. For an ongoing session, new portions of the recording also appear in intervals of up to five minutes. You can’t watch a live session in real time.
My session recording is missing user information
To associate user information with a recorded session, set the user metadata through the Faro Web SDK. Refer to how to use the user meta.
I need to prevent personally identifiable information (PII) from being recorded
Session Replay masks all input values and text content by default, client-side, before any data leaves the browser. To customize what’s masked, blocked, or ignored, configure the privacy and masking options. Refer to Data masking and Data privacy in Session Replay for details.
Was this page helpful?
Related resources from Grafana Labs


