I suspect the problem is with the actual Base64 data. Otherwise it looks good to me. See this fiddle where a similar scheme is working. You may try specifying the character set.
<div>
<p>Taken from wikpedia</p>
<img src="data:image/png;base64, iVBORw0KGgoAAAANSUhEUgAAAAUA
AAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO
9TXL0Y4OHwAAAABJRU5ErkJggg==" alt="Red dot" />
</div>
Run code snippetEdit code snippet Hide Results Copy to answer Expand
You can try this Base64 decoder to see whether your Base64 data is correct or not.
Answer from VinayC on Stack OverflowCodePen
codepen.io › jamiekane › pen › YayWOa
Base64 Image Example
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAApgAAAKYB3X3/OAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAANCSURBVEiJtZZPbBtFFMZ/M7ubXdtdb1xSFyeilBapySVU8h8OoFaooFSqiihIVIpQBKci6KEg9Q6H9kovIHoCIVQJJCKE1ENFjnAgcaSGC6rEnx...
Base64 Image Encoder
base64-image.de
Convert Images to Base64 Online — Free Encoder & Optimizer | base64-image.de
This tool supports all common web image formats: JPEG, PNG, GIF, WebP, SVG, BMP, ICO, TIFF, AVIF, and HEIC/HEIF. Each format can be compressed before encoding to reduce the base64 output size. You can also resize images or convert between formats using the options above. Have questions? Check our FAQ or read the tutorial for step-by-step instructions and code examples.
06:33
What are Base 64 Encoded Images and why are they used? - YouTube
06:26
HTML Lesson 32: Base64 Images - YouTube
03:05
Convert Image to Base64 [Use it inside img tag in HTML] - YouTube
13:19
Bring Your Own Pixels: Base64 Images in Power Apps Gallery YAML ...
16:57
Power Apps Convert Image to Base64 for Emails, PDFs and Components ...
Yulvil
yulvil.github.io › gopherjs › 02
Random base64 image
Generate an image · Or paste a base64 image · Result · Source Code
Base64.Guru
base64.guru › home › base64 converter › base64 encode
Image to Base64 | Base64 Encode | Base64 Converter | Base64
If you need to encode specific image formats, please follow the links below. ... If you do not know what output format you need, check the following examples to see how will look the result of the same Base64-encoded image formatted in each of the available formats (as an example image I use a one-pixel red dot GIF file):• Plain text:
Top answer 1 of 14
1858
I suspect the problem is with the actual Base64 data. Otherwise it looks good to me. See this fiddle where a similar scheme is working. You may try specifying the character set.
<div>
<p>Taken from wikpedia</p>
<img src="data:image/png;base64, iVBORw0KGgoAAAANSUhEUgAAAAUA
AAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO
9TXL0Y4OHwAAAABJRU5ErkJggg==" alt="Red dot" />
</div>
Run code snippetEdit code snippet Hide Results Copy to answer Expand
You can try this Base64 decoder to see whether your Base64 data is correct or not.
2 of 14
167
You need to specify the correct Content-type, Content-encoding and charset.
Like
data:image/jpeg;charset=utf-8;base64,
according to the syntax of the data URI scheme:
data:[<media type>][;charset=<character set>][;base64],<data>
Jaredwinick
jaredwinick.github.io › base64-image-viewer
Base64 Image Viewer
We cannot provide a description for this page right now
Base64.Guru
base64.guru › converter › decode › image
Base64 to Image | Base64 Decode | Base64 Converter | Base64
It's stuffed with goodies of all sorts and descriptions, but I guess that you'll be most interested in the libraries that read/write the image file format. The (current) link is https://github.com/digitickets/star-web-print/blob/master/Sample/js/StarWebPrintBuilder.js — from a very brief glimpse of the appropriate functions, my guess is that it's a simple 'raw' format with no encoding. Another hint comes from GitHub repository — there are plenty of examples there — where there is a rather large collection of BMP images.
JSFiddle
jsfiddle.net › casiano › Xadvz
base64 testing image - JSFiddle - React, Tailwind, and code Playground
JSFiddle - Test your React, Tailwind, JavaScript, CSS, HTML online with JSFiddle.
GitHub
gist.github.com › ondrek › 7413434
Smallest Base64 image · GitHub
1 pixel good for PHPs and JavaScripts because don't have any // or ++ and other symbols that can interfere(also small, only Black PNGs for What I know ): PNG Black data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAADElEQVQImWNgYGAAAAAEAAGjChXjAAAAAElFTkSuQmCC PNG Black data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVQYGWNgYGD4DwABBAEAqXIB5QAAAABJRU5ErkJggg Normal, No Code Amicable:
Base64 Image Encoder
base64-image.de › home › tutorial
Tutorial - Base64 Image Encoder
Drag & drop your images directly into the browser window · Click the upload button to select files from your computer · Once uploaded, each file will show a status indicator: ... Batch Processing: You can upload up to 20 files at once! You can use the base64 encoded string directly in your HTML <img> tag's src attribute using the data:image/... format.
Wikipedia
en.wikipedia.org › wiki › Base64
Base64 - Wikipedia
July 30, 2026 - Base64 encoding is prevalent on ... digital image in text such as HTML and CSS. ... Base64 is widely used for sending e-mail attachments, because SMTP – in its original form – was designed to transport 7-bit ASCII characters only. Encoding an attachment as Base64 before sending, and then decoding when received, assures older SMTP servers correctly transmit messages with attached binary information. ... For example, to include ...
Xoax
xoax.net › sub_html › crs_core › Lesson32
Lesson 32: Base64 Images
A conversion program for creating base64 encodings is available on our lesson page. With an ordinary image element, we set the src attribute value to the name of a file on the local file system or at a remote URL. This example uses a local image file of a small red "X" in a 9 by 9 pixel image.
Calmcode
calmcode.io › til › html-base64
TIL: Base64 Images
<img src="data:image/png;base64, <copy string here>" alt="Cat"> Back to main.
W3docs
w3docs.com › tools › image-base64
Image to Base64 Converter — Free Online Tool | W3docs
Reach for this to cut an HTTP request for a small, rarely-changing image — an icon, a logo, a placeholder — by inlining it straight into HTML, CSS, or a JSON config, instead of linking a separate file. The trade-off is size: base64 turns every 3 bytes into 4 characters, so the encoded string runs about 33% larger than the original, and an inlined image can no longer be cached independently of the page around it.
Lucid
lucid.co › techblog › 2017 › 10 › 23 › base64-encoding-a-visual-explanation
Base64 Encoding: A Visual Explanation
October 23, 2017 - An image embedded directly into an HTML image tag As a programmer, it is easy to accept this random-looking ASCII string as the “Base64 encoded” abstraction and move on. To go from raw bytes to the Base64 encoding, however, is a straightforward process, and this post illustrates how we get there.