Skip to content
Maps Embed

Implementation guide

Iframe setup, React component, and common patterns.

Basic iframe

<iframe
  src="https://www.scanner.net/sol/scanner/TOKEN_MINT/map?embed=1&key=YOUR_API_KEY"
  width="100%"
  height="600"
  sandbox="allow-scripts allow-same-origin allow-popups allow-popups-to-escape-sandbox"
  allow="clipboard-write"
  style="border: none; border-radius: 12px;"
></iframe>

Set TOKEN_MINT/YOUR_API_KEY. Use https://www.scanner.net; the apex redirects.

Robinhood: /rh/scanner/0xADDRESS/map; same key, domains, and iframe attributes. Both chains: holders, quick, deep, max. traders: Solana only.

Required sandbox tokens

TokenWhy
allow-scriptsClient-rendered map requires JavaScript
allow-same-originPreserves API origin; omission creates an opaque origin
allow-popupsExternal explorer tabs
allow-popups-to-escape-sandboxExternal tabs escape iframe sandbox

Without allow-same-origin, API calls send Origin: null and fall back to Referer. A stripped referrer leaves no usable origin; domain-restricted organizations return 403 EMBED_DOMAIN_REJECTED.

React component

function ScannerEmbed({
  address,
  chain = "sol",
  apiKey,
  mode,
  height = 600,
  className,
}: {
  address: string;
  chain?: "sol" | "rh";
  apiKey: string;
  mode?: "holders" | "traders" | "quick" | "deep" | "max";
  height?: number | string;
  className?: string;
}) {
  const params = new URLSearchParams({ embed: "1", key: apiKey });
  if (mode) params.set("mode", mode);
  const src = `https://www.scanner.net/${chain}/scanner/${encodeURIComponent(address)}/map?${params}`;

  return (
    <iframe
      title={`${chain === "rh" ? "Robinhood Chain" : "Solana"} map`}
      src={src}
      width="100%"
      height={height}
      sandbox="allow-scripts allow-same-origin allow-popups allow-popups-to-escape-sandbox"
      allow="clipboard-write"
      className={className}
      style={{ border: "none", borderRadius: 12 }}
    />
  );
}
<ScannerEmbed
  address="So11111111111111111111111111111111111111112"
  apiKey="emb_your_key_here"
  mode="holders"
/>

Robinhood: chain="rh", 0x address. mode="traders" displays an unsupported-mode message.

Wallet scans

Use a wallet address; omitted depth defaults to quick (&quick).

<iframe
  src="https://www.scanner.net/sol/scanner/WALLET_ADDRESS/map?embed=1&key=YOUR_KEY&deep"
  width="100%" height="600"
  sandbox="allow-scripts allow-same-origin allow-popups allow-popups-to-escape-sandbox"
  style="border: none;"
></iframe>
ParamSpeedResult
quick (default)FastBasic connections
deepMediumFull graph
maxSlowMaximum depth

Switching tokens dynamically

Change iframe src without reloading the host:

function loadToken(address, chain = "sol") {
  const params = new URLSearchParams({ embed: "1", key: API_KEY });
  document.getElementById("scanner-embed").src =
    `https://www.scanner.net/${chain}/scanner/${encodeURIComponent(address)}/map?${params}`;
}

Responsive sizing

Fluid aspect ratio:

<div style="position: relative; width: 100%; padding-bottom: 56.25%;">
  <iframe
    src="https://www.scanner.net/sol/scanner/TOKEN/map?embed=1&key=KEY"
    style="position: absolute; inset: 0; width: 100%; height: 100%; border: none; border-radius: 12px;"
    sandbox="allow-scripts allow-same-origin allow-popups allow-popups-to-escape-sandbox"
    allow="clipboard-write"
  ></iframe>
</div>

CSP headers

Allow both hosts in CSP for redirect compatibility:

Content-Security-Policy: frame-src 'self' https://www.scanner.net https://scanner.net;

Controls

Both chains: zoom, pan, drag, tooltips, node details, filters. Robinhood Scan this wallet retains the key in-frame. Solana adds cluster sidebar/rescans; same-address rescans within 20 seconds are refused. Navigation, login, and upgrade UI are hidden.

View this page as Markdown