---
title: "from_base64 function in Strata | Oplema"
description: "Decode a base64 text string back into its original binary BLOB value. Write it as from_base64(string) in a Strata Formula or Filter."
url: "https://oplema.com/docs/strata/functions/from-base64"
updated: "2026-11-04"
---

# from\_base64

Decode base64 text into binary data.

## Try an expression

In [Formula](https://oplema.com/docs/strata/prep/formula), enter the expression and set Output type to **VARCHAR**.

### Expression

```
from_base64('QQ==')
```

### Result

```
'A'
```

The expression returns `BLOB`. Formula stores it as `VARCHAR` in this example. To use your own data, replace the example values with column names. Keep format strings and other options as written.

Try it live in Formula

Result
| id | result |
| --- | --- |
| 1 | A |

## Arguments and types

```
from_base64(string)
```

**string**

Text

Supported signatures (1)

```
from_base64(string: VARCHAR) → BLOB
```

The result type can depend on the input types. See DuckDB for the full argument rules.

## Things to know

If the first argument is missing, the result is NULL.

## Related functions

[to\_base64

Encode binary data as base64 text.

](https://oplema.com/docs/strata/functions/to-base64)[to\_base

Converts number to a string in the given base radix, optionally padding with leading zeros to min\_length.

](https://oplema.com/docs/strata/functions/to-base)[array\_extract

Get one item from a list or one character from text by position, where 1 is the first. For a struct, choose a field by name, or by position in an unnamed struct.

](https://oplema.com/docs/strata/functions/array-extract)[ascii

Return the Unicode number of the first character in text.

](https://oplema.com/docs/strata/functions/ascii)

[Browse text](https://oplema.com/docs/strata/functions#text) [DuckDB documentation](https://duckdb.org/docs/current/sql/functions/text.html#from_base64string)

Function metadata from DuckDB, used under the [MIT license](https://github.com/duckdb/duckdb/blob/v1.5.4/LICENSE).
