Base64 Encoding
Base64 Encoding: Converts binary data into ASCII string format. Commonly used for transmitting data over media designed to handle text.
Text to Encode
Examples
Common MIME Types
text/plain - Plain texttext/html - HTMLapplication/json - JSONapplication/xml - XMLimage/jpeg - JPEG imagesimage/png - PNG imagesimage/gif - GIF imagesimage/webp - WebP imagesapplication/pdf - PDF filesapplication/zip - ZIP archivesaudio/mpeg - MP3 audiovideo/mp4 - MP4 videoAbout this tool
Features, specifications, and related tools
Key Features
What makes this tool powerful
- Text to Base64 encoding and decoding
- File to Base64 conversion for images and documents
- Batch processing for multiple files
- Preview mode with download options
- Unicode and special character support
Specifications
Technical details and settings
How Base64 Works
Binary to Text Conversion
Base64 converts binary data into a text format using 64 different ASCII characters. This makes it safe to transmit binary data over text-based protocols like email.
Encoding Process
- Binary data is split into 6-bit groups
- Each 6-bit group maps to one of 64 characters
- Characters include A-Z, a-z, 0-9, + and /
- Padding with = characters if needed
Example
Common Use Cases
Email Attachments
Encode binary files for safe transmission in email messages.
Data URLs
Embed images and files directly in HTML/CSS using data: URLs.
API Requests
Transmit binary data in JSON API requests and responses.
Configuration Files
Store binary data in text-based configuration files.
Base64 Character Set
Total: 64 characters (6 bits of information per character)
Data URL Format
Format
"Hello" encoded in Base64 with data URL prefix
Example
data:text/plain;base64,SGVsbG8=
Use
Can be used directly in HTML img tags, CSS backgrounds