> **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.concat

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

Concatenates two or more [`Hex.Hex`](/docs/utilities/hex/types#hex).

## Imports

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

## Examples

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

Hex.concat('0x123', '0x456')
// @log: '0x123456'
```

## Definition

```ts
function concat(
  values: readonly Hex[],
): Hex
```

## Parameters

### values

* **Type:** `readonly Hex[]`

The [`Hex.Hex`](/docs/utilities/hex/types#hex) values to concatenate.

## Return Type

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

`Hex`
