---
title: "upperFirst"
description: "Uppercase the first character of a string and leave the rest unchanged."
package: "@maz-ui/utils"
url: "https://maz-ui.com/ecosystem/utils/upper-first"
---

# upperFirst

> Uppercase the first character of a string and leave the rest unchanged.

- Package: `@maz-ui/utils`
- Import: `import { upperFirst } from '@maz-ui/utils/helpers/upperFirst'`
- Web: https://maz-ui.com/ecosystem/utils/upper-first

## Usage

```ts
import { upperFirst } from '@maz-ui/utils'

upperFirst('hello') // → 'Hello'
upperFirst('hELLO') // → 'HELLO'
upperFirst('') // → ''
```

## API

```ts
function upperFirst(value: string): string
```

| Parameter | Type     | Description           |
| --------- | -------- | --------------------- |
| `value`   | `string` | The string to process |

## Notes

- Does **not** lowercase the remaining characters - use [`capitalize`](./capitalize.md) for the same behaviour when you control the input shape.
