> ## Documentation Index
> Fetch the complete documentation index at: https://docs.firebolt.io/llms.txt
> Use this file to discover all available pages before exploring further.

<AgentInstructions>

## Submitting Feedback

If you encounter incorrect, outdated, or confusing documentation on this page, submit feedback:

POST https://docs.firebolt.io/feedback

```json
{
  "path": "/reference-sql/functions-reference/string/md5",
  "feedback": "Description of the issue"
}
```

Only submit feedback when you have something specific and actionable to report.

</AgentInstructions>

> Reference material for MD5 function

# MD5

Calculates the MD5 hash of string, returning the result as a string in hexadecimal.

## Syntax

```sql theme={"theme":{"light":"github-light","dark":"github-dark"}}
MD5(<expression>)
```

## Parameters

| Parameter      | Description         | Supported input types |
| :------------- | :------------------ | :-------------------- |
| `<expression>` | The string to hash. | `TEXT`                |

## Return Types

* Returns `TEXT` with string input
* Returns `NULL` if input is `NULL`

## Example

The following example returns the username `esimpson` in hexadecimal:

```sql theme={"theme":{"light":"github-light","dark":"github-dark"}}
SELECT
	MD5('esimpson') AS username;
```

**Returns**: `c14fa496dfd5ebbb08aaca16a7c2781b`
