Skip to content
    TheCalculatorsCalculate Anything. Anytime.
    HomeCalculatorsCategoriesBlogAbout
    HomeCalculatorsCategoriesBlogAbout
    1. Home
    2. Developer
    3. Base64 Encode

    Base64 Encode

    Convert any text to Base64 and back with one click. Encoding happens entirely in your browser using RFC 4648, with full UTF-8 support for emoji and international characters, so nothing is ever sent to a server.

    #base64#base64 encode#base64 decode#btoa#atob

    TheCalculators — Base64 Encode

    Printed thecalculators.com

    The input to encode or decode (UTF-8).

    Live mode: results update as you type.

    Base64 Output

    SGVsbG8sIFRoZUNhbGN1bGF0b3JzIQ==

    32 bytes produced

    Input
    22 characters
    Input Size
    22 bytes (UTF-8)
    Output Size
    32 bytes
    Expansion
    145%
    Padding "=" chars
    2

    Full output

    FieldValue
    Base64SGVsbG8sIFRoZUNhbGN1bGF0b3JzIQ==
    Plain textHello, TheCalculators!

    Copy the full output from this table.

    Base64 uses A–Z, a–z, 0–9 and +/ with = padding. It is an encoding, not encryption — never use it to protect secrets.

    Most useful next

    Base64 Output

    SGVsbG8sIFRoZUNhbGN1bGF0b3JzIQ==

    Formula

    encoded_length = 4 × ceil(bytes ÷ 3) (Base64 maps every 3 bytes to 4 characters)

    • • UTF-8 encodes the text into bytes.
    • • Each group of 3 bytes (24 bits) splits into 4 × 6-bit values.
    • • Each 6-bit value maps to one character of the 64-character alphabet; "=" pads the final group.

    Pro tips

    • • Base64 grows data by ~33% — fine for URLs of small payloads, wasteful for large files.
    • • For URLs or filenames use the base64url variant, which swaps +/ for -_ .
    • • Decoding fails on whitespace — strip line breaks before decoding.

    FAQ

    Related Calculators

    More Developer tools you might need.

    Url Encode

    Percent-encode or decode URLs and query strings instantly, with a length and overhead breakdown.

    Calculate

    Password Generator

    Generate strong random passwords with length, character-class and ambiguity controls plus entropy.

    Calculate

    Hex Calculator

    Hex arithmetic and instant conversion between hexadecimal, decimal, octal and binary.

    Calculate

    Ip Subnet Calculator

    Split IPv4 networks — network, broadcast, host range, mask, wildcard and usable hosts from any CIDR.

    Calculate
    TheCalculatorsCalculate Anything. Anytime.

    Your all-in-one destination for free online calculators. Simple. Fast. Accurate. Always here for you.

    Quick Links

    • Home
    • All Calculators
    • Categories
    • Blog
    • About Us
    • Contact

    Popular Categories

    • Health Calculators31
    • Finance Calculators62
    • Education Calculators9
    • Travel Calculators8
    • Everyday Calculators65
    • Developer Calculators7

    Resources

    • Calculator Guide
    • Tips & Tutorials
    • Calc of the Day
    • FAQs
    • Privacy Policy
    • Terms of Service
    • Sitemap

    © 2026 TheCalculators. All rights reserved. · 204 free tools and counting.

    Calculate Anything, Anytime.Made for a Smarter World

    /orCtrl Kto searchEscto close dialogsEnterto calculate