Skip to main content
Use Sender Max (min tip: 0.001 SOL) to act on Pre Confirmations. A pre-confirmation only pays off if you land your transaction first — Sender Max is the fastest way to do that. Build on Sender Max from the start to get the full benefit of Pre Confirmations.

What is preconfSubscribe?

preconfSubscribe is a Helius WebSocket method that streams Pre Confirmations — transactions delivered at the scheduled-transaction stage, before they are shredded. It is the lowest-latency transaction signal Helius offers.
The stream is not continuous. Coverage scales with the share of stake forwarding to Helius, so expect slots with no messages — handle these gaps gracefully. See Coverage.
preconfSubscribe is served from wss://beta.helius-rpc.com — the Helius Gatekeeper endpoint — rather than mainnet.helius-rpc.com. Authenticate with your API key as a query parameter.
wss://beta.helius-rpc.com/?api-key=<API_KEY>
The beta hostname refers to the Gatekeeper rollout, not the maturity of Pre Confirmations. Pre Confirmations launch on the Gatekeeper endpoint first; it will become the standard endpoint as Helius migrates traffic to Gatekeeper.

Subscribe

Send a JSON-RPC request with the preconfSubscribe method. The server responds with a subscription ID, then streams a notification for each scheduled transaction.
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "preconfSubscribe"
}

Subscribe Response

{
  "jsonrpc": "2.0",
  "result": 24040,
  "id": 1
}
Store the result — it is the subscription ID you use to unsubscribe. After this acknowledgement, notifications stream as binary frames (see below).

Notification payload

Notifications are delivered as binary WebSocket frames (not JSON). Each frame is a packed byte layout carrying a single scheduled transaction:
BytesFieldTypeDescription
0versionu8Payload schema version. Currently 1.
1–8slotu64 (little-endian)The slot the transaction is scheduled in.
9–16tx_indexu64 (little-endian)Index of the transaction within the slot.
17statusu8Transaction status: 0 = failed, 1 = success, 2 = unknown. Execution status is reported by validators on a best-effort basis — 2 when it’s unavailable.
18+transactionbincode(VersionedTransaction)The scheduled transaction, bincode-serialized.
Read the fields in order, then bincode-deserialize the remaining bytes into a VersionedTransaction to read instructions, accounts, and the signature.
Always read and check the version byte first. It is currently 1. If Helius needs to update the payload format, the version will increment — branch on it so your decoder keeps working across schema changes.
A pre-confirmation is an early signal, not a guarantee. The transaction has not yet landed onchain and could still fail or be dropped. Confirm landing through standard commitment checks before treating it as final.

Example

const WebSocket = require('ws');

const ws = new WebSocket('wss://beta.helius-rpc.com/?api-key=<API_KEY>');

ws.on('open', () => {
  ws.send(JSON.stringify({
    jsonrpc: '2.0',
    id: 1,
    method: 'preconfSubscribe'
  }));

  // Keep the connection alive
  setInterval(() => ws.ping(), 30_000);
});

ws.on('message', (data, isBinary) => {
  // The subscribe acknowledgement arrives as a JSON text frame
  if (!isBinary) {
    const msg = JSON.parse(data.toString());
    if (msg.id === 1) console.log('Subscribed, ID:', msg.result);
    return;
  }

  // Notifications arrive as binary frames:
  // version (u8) | slot (u64 LE) | tx_index (u64 LE) | status (u8) | bincode(VersionedTransaction)
  const buf = Buffer.from(data);
  const version = buf.readUInt8(0); // currently 1 — branch on this if it changes
  if (version !== 1) return; // unknown schema version; update your decoder
  const slot = buf.readBigUInt64LE(1);
  const txIndex = buf.readBigUInt64LE(9);
  const status = buf.readUInt8(17); // 0 = failed, 1 = success, 2 = unknown
  const txBytes = buf.subarray(18); // bincode-serialized VersionedTransaction

  console.log('Scheduled transaction:', { version, slot, txIndex, status, bytes: txBytes.length });
  // Deserialize txBytes (bincode) into a VersionedTransaction with your Solana tooling
});

ws.on('error', console.error);
ws.on('close', () => process.exit(1));

Unsubscribing

To stop receiving notifications, call preconfUnsubscribe with the subscription ID returned from preconfSubscribe.
{
  "jsonrpc": "2.0",
  "id": 2,
  "method": "preconfUnsubscribe",
  "params": [24040]
}
{
  "jsonrpc": "2.0",
  "result": true,
  "id": 2
}

Pricing

Pre Confirmations cost 10 credits per message — one message per streamed transaction — billed from your plan. See Credits for details.
Pre Confirmations is a new product and pricing is subject to change.

Pre Confirmations Overview

What Pre Confirmations are and where they sit in the validator pipeline.

transactionSubscribe

Stream confirmed-commitment transactions with rich filtering.