# Base64 Encode

> Encode a string to Base64.

- ID: `base64_encode`
- Type: Block
- Category: [Strings](https://inventor.bot/docs/reference/blocks/strings.md)

- Value block: it can be used directly inside expressions, e.g. `"Result: " + base64_encode(Args{...})`.

**Inputs**

| Name | Required | Description | Value |
| --- | --- | --- | --- |
| `text` | yes | String to encode. | e.g. `"hello"` |

**Outputs**

| Name | Description | Value |
| --- | --- | --- |
| `encoded_string` | Base64 encoded output. | e.g. `"aGVsbG8="` |

**Example**

```go
base64Encode := base64_encode(Args{text: "hello"})
send_text_message(Args{
	channel_id:      trigger.channel_id,
	message_content: "Encoded String: " + base64Encode,
})
```