Quick answer: “could not coalesce error” is not a blockchain error at all. It is the message ethers.js v6 throws (with code=UNKNOWN_ERROR) when your RPC node rejects a request with an error string that ethers does not recognise, so it cannot translate it into a friendlier code like INSUFFICIENT_FUNDS. The real reason is inside the error, in error.error.message, and the fix depends on what that message says.
This guide shows where the message comes from in the ethers source, what we saw when we reproduced it on a local Anvil node and against the public Core mainnet RPC, and how to fix the most common causes behind it.
What “could not coalesce error” actually means
When a JSON-RPC call fails, ethers v6 passes the node’s raw error to a function called getRpcError() in provider-jsonrpc.ts. That function tries to “coalesce” (normalise) the many different error formats used by Geth, Erigon, Anvil, Hardhat and hosted RPC providers into a small set of ethers error codes. In ethers 6.17.0 (the version installed for this article) it only recognises a handful of patterns:
eth_call/eth_estimateGasfailures becomeCALL_EXCEPTION(reverts).- “user denied” becomes
ACTION_REJECTED. - On
eth_sendRawTransaction/eth_sendTransaction: “insufficient funds” →INSUFFICIENT_FUNDS, “nonce … too low” →NONCE_EXPIRED, “replacement transaction underpriced” →REPLACEMENT_UNDERPRICED, “only replay-protected” →UNSUPPORTED_OPERATION. - “the method … does not exist” or details starting with “Unauthorized method:” →
UNSUPPORTED_OPERATION.
Anything else falls through to the last line of the function: makeError("could not coalesce error", "UNKNOWN_ERROR", { error, payload }). The ethers error docs describe UNKNOWN_ERROR as “a catch-all for when there is no way for Ethers to know what the underlying problem is.” In other words, the message is ethers saying “the node said no, and here is exactly what it said.”
What we observed when reproducing it
We ran ethers 6.17.0 on Node.js 24 against a local Anvil node (Foundry 1.9.0) and against https://rpc.coredao.org (Core mainnet, chain ID 1116). On Core we only broadcast transactions from a fresh, empty wallet that the node was guaranteed to reject, so nothing was mined. These were the results:
| What we did | Node | Raw node error | What ethers threw |
|---|---|---|---|
| Sent a tx with a 20,000 gas limit | Core mainnet | intrinsic gas too low: gas 20000, minimum needed 21000 | could not coalesce error (UNKNOWN_ERROR) |
| Sent a tx with a 1 wei gas price | Core mainnet | transaction underpriced: gas tip cap 1, minimum needed 60000000000 | could not coalesce error (UNKNOWN_ERROR) |
| Sent a tx with maxFeePerGas = 1 wei | Anvil | max fee per gas less than block base fee | could not coalesce error (UNKNOWN_ERROR) |
| Called a non-existent RPC method | Anvil | Method not found (-32601) | could not coalesce error (UNKNOWN_ERROR) |
| Called a non-existent RPC method | Core mainnet | the method eth_doesNotExist does not exist/is not available | unsupported operation (UNSUPPORTED_OPERATION) |
| eth_getBalance with a malformed address | Anvil | odd number of digits (-32602) | could not coalesce error (UNKNOWN_ERROR) |
| Sent a tx from an empty wallet | Anvil | Insufficient funds for gas * price + value | insufficient funds for intrinsic transaction cost (INSUFFICIENT_FUNDS) |
Two things stand out. First, the same mistake can produce different ethers errors depending on the node’s wording: an unknown method was coalesced to UNSUPPORTED_OPERATION on Core (Geth-style wording) but not on Anvil (“Method not found”). Second, everyday problems like a too-low gas limit or a gas price below Core’s minimum surface as “could not coalesce error”, which is why the message feels so cryptic.
A typical full message looks like this (transaction hex shortened):
could not coalesce error (error={ "code": -32000, "message": "intrinsic gas too low: gas 20000, minimum needed 21000" }, payload={ "id": 5, "jsonrpc": "2.0", "method": "eth_sendRawTransaction", "params": [ "0xf866…" ] }, code=UNKNOWN_ERROR, version=6.17.0)
How to fix it
Step 1: Read the real error, not the wrapper
Every “could not coalesce error” carries two useful properties: error (the node’s JSON-RPC error object, with code and message) and payload (the request ethers sent, including method and params). This small helper, which we ran against Anvil, prints the useful part:
const { isError } = require("ethers");
function rpcReason(e) {
if (isError(e, "UNKNOWN_ERROR") && e.error?.message) {
return `${e.payload?.method}: ${e.error.message} (code ${e.error.code})`;
}
return e.shortMessage ?? e.message;
}
// Output in our test:
// eth_sendRawTransaction: intrinsic gas too low (code -32000)
Once you have that inner message, treat it as the actual error and fix that.
Step 2: Match the inner message to a fix
- “intrinsic gas too low”: your gas limit is below the minimum (21,000 for a plain transfer). Let ethers estimate gas instead of hard-coding it. See our intrinsic gas too low guide.
- “transaction underpriced” (common on Core): the gas price is below the node’s minimum. On Core mainnet our test showed a minimum of 60,000,000,000 wei (60 gwei). Details in “transaction underpriced” on Core.
- “max fee per gas less than block base fee”: your EIP-1559
maxFeePerGasis too low for the current block. Fetch fresh values withprovider.getFeeData(). See this explainer. - “Method not found” / -32601: the node or RPC provider does not support that method. Use a different endpoint or avoid the method (for example, filter-based event listeners on providers that block
eth_newFilter). - -32602 / “invalid argument” / “odd number of digits”: a parameter is malformed. Check addresses, hex strings and block tags before sending a raw
provider.send()call. - Anything mentioning a revert: debug it as a contract revert. Our execution reverted guide covers decoding revert data.
Step 3: Update ethers
The list of recognised patterns has grown over time. For example, in ethers issue #4162 users saw “could not coalesce error” for Unauthorized method: eth_newFilter on version 6.6.0, and the maintainer said that case was added to the error coalescing in v6.6.2. If you are on an old 6.x release, upgrading may turn a vague error into a specific one. Check your version with npm ls ethers.
Step 4: If it comes from a wallet or signer
The same message can come back from a browser wallet or embedded wallet provider. In one Ethereum Stack Exchange thread, signTypedData() through a Web3Auth provider failed with “could not coalesce error” and an inner message of “Cannot read properties of null (reading ‘ok’)”; the accepted answer said that signer setup did not support eth_signTypedData_v4. If the payload.method is a signing method, the problem is usually the wallet integration rather than the chain.
Is it different on Core?
No. Core is EVM-compatible and its public RPC returned Geth-style messages in our tests, so ethers behaves the same way. The Core-specific part is the content of the inner error, especially the minimum gas price. If you are deploying contracts, our Hardhat on Core guide covers sensible gas settings.
FAQ
Is “could not coalesce error” a bug in ethers?
Usually not. It is a deliberate fallback that means ethers did not recognise the node’s error text. The node’s original message is attached to the error object.
Did my transaction go through?
If the payload method is eth_sendRawTransaction, the node rejected the transaction before adding it to the mempool, so it was not broadcast by that node. Check your address on a block explorer if you are unsure.
Why does the same code work on one RPC and fail on another?
RPC providers word errors differently and support different methods. As our tests showed, ethers maps errors by matching text, so wording changes the result.
Does ethers v5 show this error?
The wording comes from the v6 getRpcError() function linked above. When we searched the published ethers 5.8.0 and @ethersproject/providers 5.8.0 packages, the string did not appear, so v5 reports node errors differently.
Disclaimer: This article is for educational purposes only and is not financial or investment advice. Always test on a testnet or local node before sending real funds.
