[API reference](https://evolu.dev/docs/api-reference) › [@evolu/common](https://evolu.dev/docs/api-reference/common) › [Type](https://evolu.dev/docs/api-reference/common/Type) › normalize

```ts
function normalize<Form extends UnicodeNormalizationForm>(
  value: string,
  form: Form & ValidateLiteral<Form>,
): string & Brand<`Normalized${Form}`>;
```

Defined in: [packages/common/src/Type.ts:7769](https://github.com/evoluhq/evolu/blob/bc4578a260dd15d5bbf94b83765ca05984d194cb/packages/common/src/Type.ts#L7769)

Converts a string to a Unicode normalization form and returns it with the
[normalized](https://evolu.dev/docs/api-reference/common/Type/functions/normalized) brand of that form.

Normalization can change the length, so input brands are not retained.

### Example

```ts
import { assertEqual, assertType, normalize, type Brand } from "@evolu/common";

const text = normalize("cafe\u0301", "NFC");
assertEqual(text, "caf\u00E9");
assertType<typeof text, string & Brand<"NormalizedNFC">>();

assertEqual(normalize("\uFB01", "NFKC"), "fi");
```