In order for you to truly be able to understand some of the most common ETH-RPC errors, you will need to know what they essentially mean first.
JSON is a lightweight, data-interchange format that can represent numbers or strings, ordered sequences of values, and even collections of name and value pairs. Then there’s JSON-RPC, which is this stateless, lightweight remote procedure call or RPC protocol.
This is a specification that essentially defines several data structures, as well as the rules around their processing, and is transport agnostic in that the concepts can be used within the same process over various message passing environments.

That said, as a means of talking to an Ethereum node from inside a JavaScript application, developers can use the web3.js library, which gives a convenient interface for the RPC methods.
However, there are a plethora of different errors which can occur throughout this procedure, so knowing what they are and how they can aid you within the overall development process.
Knowing these errors can play an essential role in the overall development process, as you will be fully able to analyze the code, know what to look out for, and can resolve any issues that you might encounter with ease, which will ultimately lessen the strain you have throughout the coding procedure and lead to better code.
Additionally, each of these codes has a number associated with them, so locating them and getting an indication of what they mean is simpler than ever before.
As such, today, we are going to go over some of the most popular ETH-RPC errors that you need to be aware of.
Popular ETH-RPC Errors
Here are some of the most popular Ethereum RPC errors, which also include Ethereum JSON RPC and Ethereum Provider errors.

When it comes to the basic usage of these errors, you can utilize TypeScript or JavaScript by entering the following code:
import { ethErrors } from ‘eth-rpc-errors’
throw ethErrors.provider.unauthorized()
// or
throw ethErrors.provider.unauthorized(‘my custom message’)
When it comes to the supported errors, you have:
- Ethereum JSON RPC per EIP-1474, which includes all JSON RPC 2.0 errors.
The EIP-1474 errors are the following:
Code | Message | Meaning | Category |
-32700 | Parse error | Invalid JSON Error | standard |
-32600 | Invalid request | JSON is not a valid request object Error | standard |
-32601 | Method not found | Method does not exist error | standard |
-32602 | Invalid params | Invalid method parameters error | standard |
-32603 | Internal error | Internal JSON-RPC error | standard |
-32000 | Invalid input | Missing or invalid parameters error | non-standard |
-32001 | Resource not found | Requested resource not found error | non-standard |
-32002 | Resource unavailable | Requested resource not available error | non-standard |
-32003 | Transaction rejected | Transaction creation failed error | non-standard |
-32004 | Method not supported | Method is not implemented error | non-standard |
-32005 | Limit exceeded | Request exceeds defined limit error | non-standard |
-32006 | JSON-RPC version not supported | Version of JSON-RPC protocol is not supported error | non-standard |
- Ethereum Provider Errors per EIP-1193, which does not yet support CloseEvent errors or status codes.
The EIP-1193 errors are the following:
Status code | Name | Description |
4001 | User Rejected Request | The user rejected the request error |
4100 | Unauthorized | The requested method and, or account has not been authorized by the user error |
4200 | Unsupported Method | The Provider does not support the requested method error |
4900 | Disconnected | The Provider is disconnected from all chains error |
4901 | Chain Disconnected | The Provider is not connected to the requested chain error |
When it comes to the usage, you can install them by using the following codes:
- npm install eth-rpc-errors
- yarn add eth-rpc-errors
After which you can import or require as normal, as there is no default export. Note that the package is implemented in TypeScript and that all of the exports are typed.
Here is what the Errors API looks like:

When it comes to parsing unknown errors, here is what you need to know:

As for the other exports, here is what you need to do:

If you have an interest in utilizing these popular ETH-RPC errors, you might want to be connected to an Ethereum node. If this is the case, you can use the blockchain-as-a-service provider NOWNodes as a means of accessing an ETH node through the usage of an API key. All you have to do is connect with your email address, after which you will be able to receive the free API key.

Conclusion
Hopefully, now you have a heightened perspective, as well as a broader level of understanding when it comes to some of the most popular ETH-RPC errors you will encounter while developing for the Ethereum blockchain. If you are curious about developing on Ethereum, you can utilize a NOWNodes node as a means of getting blockchain data at any time when you require it.
GET ACCESS TO ETHEREUM