Replays are typically viewed in session replay part of PostHog, but sometimes, you might want to share them internally or externally.
We provide multiple ways for you to do so.
Sharing (and embedding) a session replay
On every session replay, you'll see a share button.


This enables you to share the replay directly in three different ways:
Private link: A direct link to the replay only accessible by teammates added to your project.
Public link: A direct link to the replay that can be shared with anyone. It can also be used to embed the replay in a webpage using an iframe like this:
<iframe width="100%" height="400" frameborder="0" allowfullscreen src="https://us.posthog.com/embedded/Bi48yMpp9pFCZJMmGe_h3-gMDwlBrQ"></iframe>
- Share to Linear: You can add an issue to Linear from a replay that will include a link to the replay along with the title and description you set. You can connect your Linear account in your project settings.
Sharing a collection
If you want to share multiple replays internally, such as for a product review, you can create a collection.
Click the + Add to collection button next to the Share button on a replay, search or create a new collection, and then select it. You can then go to the collection page, find that collection, and share the link to anyone with access to your PostHog project.
Sharing a screenshot
If you just want to share an image from the replay, you can click the Screenshot button. This opens a modal with the current frame and enables you to add text or drawings to it. You can then download and share the image.
Method two: Automatically share replays to Intercom or Crisp
You can automatically share replays to Intercom or Crisp by setting the integrations
config option when initializing PostHog's Web SDK to { intercom: true }
or { crispChat: true }
.
posthog.init('<ph_project_api_key>', {api_host: 'https://us.i.posthog.com',integrations: {intercom: true,crispChat: true,},});
When enabled, this:
- Automatically sets the latest session replay URL and person profile URL to Intercom or Crisp
- Tracks a PostHog event (
posthog:sessionInfo
) in Intercom with replay and person URLs - Updates whenever a new session starts
This requires the respective chat widget (Intercom or Crisp Chat) to be installed and configured on your site. The integrations only activates if the chat widgets are detected on the page.
Method three: Sharing via the PostHog API
Using the PostHog API, you can automate the sharing of replays. For example, a common use case is to include a session replay in a support ticket whenever a user reports a bug.
Here is how to use the API to share replays:
- In your frontend, retrieve the
session_id
of the replay you want to share. Then, upload thatsession_id
to your backend
// Frontend - where the recording is taking placeconst sessionID = posthog.get_session_id()// Upload this sessionID to your backenduploadSessionIDToBackend(sessionID)
- Once you have the
session_id
in your backend, you can enable sharing for that recording using the API to create an access token.
// Node.JS backend exampleconst projectID = 123 // Found in [Project Settings](https://us.posthog.com/project/settings)const sessionID = '{FROM_STEP_1}'const url = `https://us.posthog.com/api/projects/${projectID}/session_recordings/${sessionID}/sharing?personal_api_key=${POSTHOG_PERSONAL_API_KEY}`const response = await fetch(url, {method: 'PATCH',body: JSON.stringify({enabled: true,}),headers: {'Content-type': 'application/json;',},}).then((res) => res.json())// You can also retrieve the access token again by calling the same endpoint// const response = await fetch(url).then((res) => res.json())const accessToken = response.accessToken
- You can now share the replaying using the access token and an iframe:
<iframeallowfullscreenwidth="100%"height="450"frameborder="0"src="https://app.posthog.com/embedded/{accessToken}"></iframe>
Limitations
We make no guarantees about sensitive information contained in the recording. We recommend you only sharing recordings that you are certain contain no sensitive information or embed them only where authorized users can see them.
Events will not be shown in the shared iframe, as they are loaded from a separate endpoint that is not accessible from the embedded iframe.
If your replays look incorrect or buggy, be sure to read our troubleshooting docs on how to debug this.