Home Explore Blog CI



nushell

1st chunk of `commands/docs/encode_base32.md`
edcd4f77bc4f564cbf5dd6f6e80884e72d5c6eeb72dafb8f0000000100000417
---
title: encode base32
categories: |
  formats
version: 0.104.0
formats: |
  Encode a string or binary value using Base32.
usage: |
  Encode a string or binary value using Base32.
editLink: false
contributors: false
---
<!-- This file is automatically generated. Please edit the command in https://github.com/nushell/nushell instead. -->

# `encode base32` for [formats](/commands/categories/formats.md)

<div class='command-title'>Encode a string or binary value using Base32.</div>

## Signature

```> encode base32 {flags} ```

## Flags

 -  `--nopad`: Don't accept padding.


## Input/output types:

| input  | output |
| ------ | ------ |
| binary | string |
| string | string |
## Examples

Encode a binary value
```nu
> 0x[01 02 10] | encode base32
AEBBA===
```

Encode a string
```nu
> "hello there" | encode base32
NBSWY3DPEB2GQZLSMU======
```

Don't apply padding to the output
```nu
> "hi" | encode base32 --nopad
NBUQ
```

## Notes
The default alphabet is taken from RFC 4648, section 6.

Note this command will collect stream input.

Title: encode base32
Summary
The `encode base32` command encodes a string or binary value using Base32 encoding. It supports a `--nopad` flag to omit padding. The command accepts binary or string input and outputs a Base32 encoded string. The default alphabet is taken from RFC 4648, section 6. This command will collect stream input.