Skip to main content

Disabling Autopilot Session Recording

Autopilot is the session-recording SDK. It is loaded by Pulse, not integrated on its own, and it only starts recording when both a Pulse config flag and a remote setting allow it (see Autopilot → Initialization & Enablement).

By default Autopilot is off. For applications/segments where it is turned on server-side, an integrator can still opt out from the client so the Autopilot bundle is never loaded on their pages. This is done with a single Pulse config field:

autopilotTracking: { enabled: false }

When a client passes autopilotTracking.enabled === false, Pulse skips loading Autopilot entirely — no recording, no Autopilot bundle request — even if the server segment config and the remote setting would otherwise enable it.

note

This is a kill switch only. Setting enabled: false guarantees Autopilot is not loaded. Setting enabled: true does not force recording on by itself — the remote autopilot/autopilot_config setting must also allow it. See Autopilot → Initialization & Enablement.

How to pass the config

The autopilotTracking field is part of the standard Pulse configuration, so it travels through the same channels as every other config value. You can use whichever channel matches your integration.

@pulse/browser

Pass it in the initialize config:

import { initialize } from "@pulse/browser";

const pulse = initialize({
app: "your application name",
defaults: {},
remoteSettingEnabled: true,
autopilotTracking: { enabled: false },
});

@pulse/react

The PulseProvider accepts settings and tracker config objects. Pass autopilotTracking through the tracker object:

import { PulseProvider } from "@pulse/react";

const Shell = () => (
<PulseProvider
app="your application name"
tracker={{ autopilotTracking: { enabled: false } }}
>
{/* ...rest of application components */}
</PulseProvider>
);

Loader <script> URL query param

If you preload the Pulse loader script in your HTML (see Integration Guide → Pulse loader configuration), you can disable Autopilot directly from the script src with the autopilot query param — no application code or SDK config needed:

<script
type="module"
src="https://optifyr.com/pulse/{{appName}}/module/pulse.js?include=settings,tracker&autopilot=false"
async
fetchpriority="high"
></script>
<script
nomodule
src="https://optifyr.com/pulse/{{appName}}/nomodule/pulse.js?include=settings,tracker&autopilot=false"
async
fetchpriority="high"
></script>

The param is resolved server-side into config.autopilotTracking.enabled, overriding the per-segment server default.

Param valueEffect
autopilot=false (also 0, off, no)Force Autopilot off for this page load.
autopilot=true (also 1, on, yes)Request Autopilot on (still subject to the remote setting — Gate 2).
omitted / unrecognizedNo effect — the server segment default applies.

Add the same param to both the module and nomodule script tags so the behavior is consistent across browsers.

localStorage override

For QA/automation, or to force the opt-out at runtime without changing code, use the config override localStorage key. The value is a JSON string and is merged into the effective config at bootstrap:

localStorage.setItem(
"paa_config_override",
JSON.stringify({ autopilotTracking: { enabled: false } })
);

The key is {storagePrefix}config_override — with the default storagePrefix of paa_, that is paa_config_override. The value must be set before Pulse initializes.

Precedence

The effective autopilotTracking value is resolved in this order, with later sources overriding earlier ones:

#SourceNotes
1Server segment configSet per app/segment by the Pulse loader Worker; default { enabled: false }.
2Loader URL query param (?autopilot=)Resolved server-side; overrides the segment default.
3Client config (initialize / PulseProvider)An SDK-level client value overrides the server-resolved value (segment + URL param).
4localStorage override (paa_config_override)Overrides everything; intended for QA/automation.

Each later source overrides the earlier ones, so passing autopilotTracking: { enabled: false } (or ?autopilot=false) reliably disables Autopilot even in segments where the server enabled it.

tip

You only need this if Autopilot is enabled for your application. If it is already off for you, no action is required — the default is { enabled: false }.