# Mnemonic.validate

Checks if a mnemonic is valid, given a wordlist.

## Imports

:::code-group
```ts [Named]
import { Mnemonic } from 'ox'
```

```ts [Entrypoint]
import * as Mnemonic from 'ox/Mnemonic'
```
:::

## Examples

```ts twoslash
import { Mnemonic } from 'ox'

const mnemonic = Mnemonic.validate(
  'buyer zoo end danger ice capable shrug naive twist relief mass bonus',
  Mnemonic.english
)
// @log: true
```

## Definition

```ts
function validate(
  mnemonic: string,
  wordlist: string[],
): boolean
```

**Source:** [src/core/Mnemonic.ts](https://github.com/wevm/ox/blob/main/src/core/Mnemonic.ts#L232)

## Parameters

### mnemonic

* **Type:** `string`

The mnemonic to validate.

### wordlist

* **Type:** `string[]`

The wordlist to use.

## Return Type

Whether the mnemonic is valid.

`boolean`
