What is Base64?
Base64 is an encoding scheme that converts binary data into text format. This allows images to be embedded directly in HTML, CSS, or JSON without separate files.
When to Use Base64 Images
- Embedding small icons and logos
- Reducing HTTP requests
- Inline images in emails
- Data URIs in CSS
Pros & Cons
✅ Pros: Fewer HTTP requests, portable, works offline
❌ Cons: Larger file size (~33% increase), not cacheable separately