Skip to main content

Documentation Index

Fetch the complete documentation index at: https://bun.com/docs/llms.txt

Use this file to discover all available pages before exploring further.

Bun implements the Web-standard atob and btoa functions for encoding and decoding base64 strings.
const data = "hello world";
const encoded = btoa(data); // => "aGVsbG8gd29ybGQ="
const decoded = atob(encoded); // => "hello world"

See Docs > Web APIs for a complete breakdown of the Web APIs implemented in Bun.