Convert an image to a Base64 data URL or decode image data in your browser. Copy a data URL and preview the decoded image with PSDevTool.
The interactive workspace opens with JavaScript.
Read the tool guide ↓Move between an image file and its text representation. Image Base64 helps create data URLs for development and inspect encoded image content.
PRACTICAL WALKTHROUGH
A data URL lets text carry an image’s bytes and media type. It can help with a small inline asset, but embedding a large image also enlarges the surrounding document and can reduce the benefits of normal image caching.
For a 3-byte source, Base64 uses 4 encoded characters. A data URL also adds a prefix such as data:image/png;base64,
Approximate encoded length: 4 × ceil(source bytes / 3), plus the data-URL prefix.
Use the preview to verify that the media type and encoded bytes describe the expected image. If the result does not render, inspect the prefix and copied content instead of assuming every Base64 string is an image.
No. Base64 represents binary data as text and typically adds overhead. Resize or compress the image first if you need a smaller asset.
Check that the input is complete, correctly encoded and actually contains supported image data. A data URL’s media type should match the content.