Skip to content

IPFS Gateways

The bridge between the traditional web and the IPFS network.

Gateways list page showing available IPFS gateways

Public vs. dedicated gateways

FeaturePublic gatewayDedicated gateway
URLipfs.ninja/ipfs/...<slug>.gw.ipfs.ninja/ipfs/...
ServesAny CID from the networkOnly your pinned CIDs
AuthenticationNoneOptional (token, IP whitelist)
PlanAll plansPaid plans only (Bodhi/Karma/Nirvana)

What is a gateway?

An IPFS gateway is an HTTP server that translates standard web requests into IPFS protocol requests. It lets browsers, apps, and scripts access IPFS content without running an IPFS node — just use a regular URL.

https://ipfs.ninja/ipfs/<CID>

When you request this URL, the gateway fetches the content from the IPFS network (or its cache), and returns it as a standard HTTP response.

How gateways resolve content

  1. You request ipfs.ninja/ipfs/QmXk7...
  2. The gateway checks its local cache — if the file is cached, it's returned immediately
  3. If not cached, the gateway queries the IPFS DHT to find nodes that have the CID
  4. The gateway downloads the file from the nearest available node
  5. The file is cached locally and returned to you as an HTTP response

Cross-origin access (CORS)

By default, browsers block JavaScript running on one origin from reading the response of a request made to a different origin — a security mechanism called the same-origin policy. CORS (Cross-Origin Resource Sharing) is how a server opts back in: response headers that tell the browser "it's safe for this origin to read my response."

The shared apex gateway (ipfs.ninja/ipfs/<CID>) sends CORS headers on every response, so browser code on any website can fetch() a gateway URL, or load it into an <img>/<canvas>, without the browser blocking access to the bytes. This matters for anything that reads pixel data or response bytes in JS — a canvas-based image editor pulling in IPFS-hosted artwork, for example — since without CORS headers the browser "taints" the canvas and refuses toDataURL()/getImageData() calls.

See API Reference → Gateways → Cross-origin reads (CORS) for the exact response headers and request examples.

Other public gateways

Since IPFS is a public network, your files are accessible through any IPFS gateway — not just ours. Popular public gateways include:

  • dweb.link/ipfs/<CID> — Protocol Labs
  • w3s.link/ipfs/<CID> — Storacha (Web3.Storage)
  • ipfs.io/ipfs/<CID> — Protocol Labs (legacy, sometimes rate-limited)

See also IPFS Pinning and the Upload API reference.