# ASCII

Returns the ASCII value of the leftmost character of the given string.

## Syntax

```sql
ASCII (str)

```

## Arguments

* `str`: any string or binary object

> **📝 Note**: ASCII only works with 8-bit characters.

## Return Type

Integer, or NULL if str is NULL.

## Examples

```sql
SELECT ASCII('abracadabra');

```

```output

+----------------------+
| ASCII('abracadabra') |
+----------------------+
|                   97 |
+----------------------+

```

***

Modified at: April 3, 2023

Source: [/db/v9.1/reference/sql-reference/string-functions/ascii/](https://docs.singlestore.com/db/v9.1/reference/sql-reference/string-functions/ascii/)

(An index of the documentation is available at /llms.txt)
