starname.me

How to interpret an RPC endpoint URL structure

An nodes/rpc-endpoint-basics/">RPC endpoint URL is a web address your wallet or dApp sends requests to when it needs to read blockchain data or submit a transaction. You interpret it by splitting it into four parts: the protocol, the hostname, the port, and the path. Each part tells you something about who runs the node, what chain it serves, and how you connect to it.

The four parts of an RPC URL

Every RPC endpoint URL follows the same general pattern:

<protocol>://<hostname>:<port>/<path>

Protocol

Most RPC endpoints use either http:// or https://. The difference is encryption. HTTPS encrypts your requests; HTTP sends them in plain text. A public RPC provider should offer HTTPS. If you see HTTP, the connection is unencrypted, which means anyone on the network can read the requests and responses. Some local nodes use HTTP because the traffic never leaves your machine.

A small number of endpoints use wss:// or ws:// for WebSocket connections. These are used for real-time subscriptions (like pending transaction alerts) rather than one-off requests. The URL structure is otherwise the same.

Hostname

The hostname tells you who provides the node. There are three common patterns:

Provider domains - Services like Infura, Alchemy, QuickNode, or public endpoints hosted by projects. The hostname usually includes the provider name, for example eth-mainnet.g.alchemy.com or mainnet.infura.io. These are third-party nodes. You do not control them.

Chain-specific domains - Some blockchains host their own public endpoints. For example, a Cosmos chain might use https://rpc.cosmos.network. The hostname often includes the word "rpc" or the chain name.

Localhost or IP address - If you run your own node, the endpoint is typically http://localhost or http://127.0.0.1. Some setups use http://192.168.x.x if the node is on another machine on your local network.

Port

The port number is optional. If omitted, the browser or client uses the default: 80 for HTTP, 443 for HTTPS. Many RPC providers omit the port entirely and rely on the default.

When a port is specified, it is usually because the provider runs multiple services on the same machine. Common ports include:

If you see a non-standard port, the provider is running the RPC service on a port that differs from the default for that protocol.

Path

The path is the least standardised part. It can be empty, a single slash, or a long string of identifiers. Common patterns include:

How to tell what chain an endpoint serves

The URL alone does not always tell you which blockchain the endpoint serves. A hostname like rpc.ankr.com could serve Ethereum, BNB Chain, Polygon, or dozens of others. The path might include the chain name, or it might not.

You can check the chain by sending a eth_chainId request (for EVM chains) or the equivalent method for non-EVM chains. Most wallets and dApps do this automatically when you add a network. If you are adding an endpoint manually and the chain ID does not match what you expect, the endpoint is either misconfigured or pointing to the wrong chain.

Why some URLs look different

Not every RPC endpoint follows the pattern above. A few variations exist:

IPFS or DNS-based endpoints - Some providers use subdomains that resolve to different servers based on your location. The URL looks normal, but the actual server you reach may change.

Tor or onion endpoints - If you see .onion in the hostname, the endpoint is accessible only through the Tor network. These are rare and used for privacy.

Local Unix sockets - Some node configurations use a file path instead of a network address. These look like ipc:///home/user/.ethereum/geth.ipc. They are faster than TCP but only work when the client and node are on the same machine.

What a broken URL looks like

Common mistakes in RPC endpoint URLs include:

If you are copying an endpoint from a provider dashboard or a site like Chainlist, check each part of the URL before pasting it into your wallet. A single character error can send your request to the wrong server or to no server at all.

Not financial advice. starname.me publishes market data and general information about digital assets. Crypto assets are volatile and you can lose everything you put in. Nothing here is a recommendation to buy, sell or hold, and we make no price predictions.

Prices are sourced from third parties and may be delayed or wrong. Verify anything you intend to act on against a primary source.

Back to rpc & nodes