Links

API key

All requests to Infura must have a valid API key appended to the request URL or they will fail.
The API key was previously called the project ID. Find the API key in the ENDPOINTS tab of your project settings.

Add the API key to requests

HTTPS
WebSocket
curl https://mainnet.infura.io/v3/<YOUR-API-KEY> \
-X POST \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"eth_accounts","params":[],"id":1}'
wscat -c wss://mainnet.infura.io/ws/v3/<YOUR-API-KEY>
> {"jsonrpc":"2.0","method":"eth_accounts","params":[],"id":1}