Skip to main content
Interfere uses TanStack Start’s Vite build and request middleware to capture browser sessions and server requests. The React provider connects browser capture to your route tree, while trace metadata connects browser and server work. The server integration requires Node.js. Start with a surface and keep your existing router options and deployment adapter as you follow the steps below.

Setup

1

Install and connect the build

Add the Interfere plugin to vite.config.ts. Keep your existing plugins, aliases, and deployment adapter. TanStack Start must precede the React plugin:
vite.config.ts
2

Set browser and server keys

Copy the keys from your surface into the build environment:
Provide INTERFERE_PUBLIC_KEY and INTERFERE_ENVIRONMENT to the server runtime too. Use production for production deployments. Keep the secret key in the build environment.The server integration requires a Node.js runtime. The Cloudflare Workers deployment integration does not provide Node.js server instrumentation.
3

Initialize browser capture

Add init() to your router module, guarded so it runs only in the browser. Preserve your existing router options:
src/router.tsx
4

Capture server requests

Add these request middleware entries to src/start.ts. Initialization runs before Interfere opens a span for the request. Keep any existing middleware in the array:
src/start.ts
5

Connect the root route

Add the provider around your root route’s content and include traceMeta() in the head metadata. Preserve your existing document shell, styles, providers, and error boundaries. The example below shows where these additions fit.
src/routes/__root.tsx
Set consent at browser initialization and review replay masking before recording customer sessions.

Verify capture

Build and deploy to staging. Report a test error from an existing browser event handler, then from a server handler, to check both sides:
Check the surface’s event chart for incoming traffic. Keep the server running long enough to send its telemetry, then remove the test calls.

Next steps

User tracking, review configuration, or follow the investigation walkthrough once a problem appears.