> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chainstack.com/llms.txt
> Use this file to discover all available pages before exploring further.

# eth_getBalance | Hyperliquid EVM

> The eth_getBalance JSON-RPC method returns the balance of an account at a given block number. Chainstack Hyperliquid EVM reference.

<Info>
  This method is available on Chainstack. Not all Hyperliquid methods are available on Chainstack, as the open-source node implementation does not support them yet — see [Hyperliquid methods](/docs/hyperliquid-methods) for the full availability breakdown.
</Info>

The `eth_getBalance` JSON-RPC method returns the balance of an account at a given block number. This method is fundamental for checking account balances and is essential for wallet applications, portfolio tracking, and balance verification.

## Parameters

The method takes two parameters:

1. **Address** - The account address to check the balance for
2. **Block parameter** - The block at which to check the balance

### Parameter details

* `address` (string, required) — The 20-byte account address to check the balance for
* `block` (string, required) — Block identifier: `"latest"` (only the latest block is supported on Hyperliquid)

## Response

The method returns the account balance in wei as a hexadecimal string.

### Response structure

**Account balance:**

* `result` — The account balance in wei as a hexadecimal string

### Data interpretation

**Balance format:**

* Returned as hexadecimal string with `0x` prefix
* Value represents wei (smallest unit of HYPE)
* Convert to HYPE by dividing by 10^18
* Convert to gwei by dividing by 10^9

**Unit conversions:**

* 1 HYPE = 10^18 wei
* 1 gwei = 10^9 wei
* Example: `0xde0b6b3a7640000` = 1,000,000,000,000,000,000 wei = 1 HYPE

## Hyperliquid-specific considerations

### Block limitations

**Latest block only:**

* Only the `"latest"` block parameter is supported
* Historical balance queries are not available in the default implementation
* All balance checks return the current state
* For historical data, consider using archive node implementations

### Balance monitoring

**Real-time tracking:**

* Check balances at regular intervals for portfolio tracking
* Monitor balance changes for transaction confirmation
* Set up alerts for significant balance changes
* Use current balance for all transaction validations

## Example request

<CodeGroup>
  ```shell Shell theme={"system"}
  curl -X POST \
    -H "Content-Type: application/json" \
    -d '{"jsonrpc":"2.0","method":"eth_getBalance","params":["0xFC1286EeddF81d6955eDAd5C8D99B8Aa32F3D2AA","latest"],"id":1}' \
    https://hyperliquid-mainnet.core.chainstack.com/4f8d8f4040bdacd1577bff8058438274/evm
  ```

  ```python web3.py theme={"system"}
  from web3 import Web3

  w3 = Web3(Web3.HTTPProvider("YOUR_CHAINSTACK_ENDPOINT"))

  balance = w3.eth.get_balance("0xFC1286EeddF81d6955eDAd5C8D99B8Aa32F3D2AA", "latest")
  print(balance)
  ```

  ```javascript ethers.js theme={"system"}
  import { JsonRpcProvider } from "ethers";

  const provider = new JsonRpcProvider("YOUR_CHAINSTACK_ENDPOINT");

  const balance = await provider.getBalance("0xFC1286EeddF81d6955eDAd5C8D99B8Aa32F3D2AA", "latest");
  console.log(balance);
  ```

  ```typescript viem theme={"system"}
  import { createPublicClient, http } from "viem";

  const client = createPublicClient({
    transport: http("YOUR_CHAINSTACK_ENDPOINT"),
  });

  const balance = await client.getBalance({
    address: "0xFC1286EeddF81d6955eDAd5C8D99B8Aa32F3D2AA",
    blockTag: "latest",
  });
  console.log(balance);
  ```
</CodeGroup>

<Note>
  **Use your own endpoint in your code.** The code examples use a placeholder Chainstack endpoint (YOUR\_CHAINSTACK\_ENDPOINT) — replace it with your own Hyperliquid node endpoint from the [Chainstack console](https://console.chainstack.com/). The curl above uses a shared public endpoint for quick checks only; do not use it in production.
</Note>

## Use cases

The `eth_getBalance` method is essential for applications that need to:

* **Wallet applications**: Display current account balances to users
* **Portfolio tracking**: Monitor balances across multiple accounts
* **Transaction validation**: Verify sufficient balance before transactions
* **DeFi protocols**: Check user balances for protocol interactions
* **Analytics platforms**: Track account balance changes over time
* **Audit systems**: Generate balance reports for compliance
* **Trading platforms**: Verify account balances for trading operations
* **Payment systems**: Check sender balances before processing payments
* **Gaming applications**: Monitor in-game currency balances
* **Staking platforms**: Verify balances for staking operations
* **Lending protocols**: Check collateral balances and ratios
* **Insurance platforms**: Monitor account balances for coverage
* **Cross-chain bridges**: Verify balances before bridge operations
* **Governance systems**: Check voting power based on token balances
* **NFT marketplaces**: Verify buyer balances for purchases
* **Subscription services**: Monitor account balances for recurring payments
* **Risk management**: Track account balances for liquidation monitoring
* **Compliance tools**: Generate balance reports for regulatory requirements
* **Educational platforms**: Demonstrate balance concepts and calculations
* **Research tools**: Analyze account balance distributions and patterns
* **Monitoring systems**: Alert on significant balance changes
* **Integration services**: Provide balance data to external systems
* **Development tools**: Test applications with various balance scenarios
* **User experience**: Provide real-time balance feedback
* **Security systems**: Monitor for unusual balance changes or activities

This method provides fundamental account balance information, enabling comprehensive account management and financial tracking on the Hyperliquid EVM platform.

<Note>
  On Hyperliquid, `eth_getBalance` only supports the latest block. Historical balance queries are not supported in the default RPC implementation. All balance queries return the current account state.
</Note>


## OpenAPI

````yaml openapi/hyperliquid_node_api/hyperevm/evm_eth_get_balance.json post /evm
openapi: 3.0.0
info:
  title: Hyperliquid EVM API - eth_getBalance
  version: 1.0.0
servers:
  - url: >-
      https://hyperliquid-mainnet.core.chainstack.com/4f8d8f4040bdacd1577bff8058438274
security: []
paths:
  /evm:
    post:
      summary: eth_getBalance
      description: Returns the balance of an account at a given block number.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - jsonrpc
                - method
                - params
                - id
              properties:
                jsonrpc:
                  type: string
                  enum:
                    - '2.0'
                  default: '2.0'
                  description: JSON-RPC version
                method:
                  type: string
                  enum:
                    - eth_getBalance
                  default: eth_getBalance
                  description: The RPC method name
                params:
                  type: array
                  description: 'Parameters: [address, block]'
                  default:
                    - '0xFC1286EeddF81d6955eDAd5C8D99B8Aa32F3D2AA'
                    - latest
                id:
                  type: integer
                  default: 1
                  description: Request identifier
            example:
              jsonrpc: '2.0'
              method: eth_getBalance
              params:
                - '0xFC1286EeddF81d6955eDAd5C8D99B8Aa32F3D2AA'
                - latest
              id: 1
      responses:
        '200':
          description: Successful response with the account balance
          content:
            application/json:
              schema:
                type: object
                properties:
                  jsonrpc:
                    type: string
                    description: JSON-RPC version
                  id:
                    type: integer
                    description: Request identifier
                  result:
                    type: string
                    description: The account balance in wei as a hexadecimal string
              example:
                jsonrpc: '2.0'
                id: 1
                result: '0xde0b6b3a7640000'

````