To build applications on Near, developers need a way to read data from the blockchain (like checking an account balance) or write data (like sending a transaction). This is done via RPC (Remote Procedure Call) endpoints.
This guide outlines how to connect to public RPCs and best practices for managing connection limits.
Public vs. Private RPCs
- Public RPCs: These are free endpoints provided by the Near Foundation or community partners. They are excellent for testing and light usage.
- Rate Limits: Public nodes often limit the number of requests you can send per second to prevent spam.
- Private RPCs: For production-grade dApps, developers usually run their own node (see our Node Anatomy guide) or pay for a private provider to ensure 100% uptime.
The Endpoint List
For developers configuring their config.js or near-cli, here are the standard
entry points:
Mainnet (Live Production)
Testnet (Development Environment)
How to Verify a Connection
You can test the status of the network using a simple cURL command in your terminal. This requests the general status of the node you are connecting to:
If the node is healthy, it will return a JSON object containing the latest_block_height and
sync_info. If the syncing boolean is false, the node is fully up to date and ready to
accept transactions.