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

# Get block hash

Retrieves a Bitcoin block hash for a given block height.

This method will use `10` [Compute Units](/nodeapi/about/billing).

***

## **Reference:** [**Here**](https://github.com/trezor/blockbook/blob/master/docs/api.md#get-block-hash)

```bash theme={"theme":{"light":"github-light","dark":"github-dark-default"}}
GET /api/v2/block-index/<block height>
```

## **Parameters**

**`block height`**- string, required.

Example: `785365`

## Returns

```json theme={"theme":{"light":"github-light","dark":"github-dark-default"}}
{
  "blockHash": "00000000000000000004a49543c0b6e2043e67b513c0d9100fbdf91f662c3ad1"
}
```

<CodeGroup>
  ```bash title="mainnet" theme={"theme":{"light":"github-light","dark":"github-dark-default"}}
  curl https://mainnet.bitcoin.validationcloud.io/v1/<YOUR_API_KEY_HERE>/api/v2/block-index/785365 \
   -X GET \
   -H "Content-Type: application/json"
  ```

  ```bash title="testnet" theme={"theme":{"light":"github-light","dark":"github-dark-default"}}
  curl https://testnet.bitcoin.validationcloud.io/v1/<YOUR_API_KEY_HERE>/api/v2/block-index/785365 \
   -X GET \
   -H "Content-Type: application/json"
  ```
</CodeGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.