> **Can't find what you're looking for?** Use `search_docs` on the docs MCP server at `https://v3.viem.sh/api/mcp` to find what you need.

# Hex.isEqual

:::info
`Hex.isEqual` is a re-export of ox's [`Hex.isEqual`](https://oxlib.sh/api/Hex/isEqual). Refer to the ox documentation for the full reference.
:::

Checks if two [`Hex.Hex`](/docs/utilities/hex/types#hex) values are equal.

## Imports

```ts
import { Hex } from 'viem/utils'
```

## Examples

```ts twoslash
// @noErrors
import { Hex } from 'viem/utils'

Hex.isEqual('0xdeadbeef', '0xdeadbeef')
// @log: true

Hex.isEqual('0xda', '0xba')
// @log: false
```

## Definition

```ts
function isEqual(
  hexA: Hex,
  hexB: Hex,
): boolean
```

## Parameters

### hexA

* **Type:** `Hex`

The first [`Hex.Hex`](/docs/utilities/hex/types#hex) value.

### hexB

* **Type:** `Hex`

The second [`Hex.Hex`](/docs/utilities/hex/types#hex) value.

## Return Type

`true` if the two [`Hex.Hex`](/docs/utilities/hex/types#hex) values are equal, `false` otherwise.

`boolean`
