Placeholder Image Generator

Set a size and colors — the preview and markup below update as you go. The label defaults to the image's own dimensions but can be overridden.

How it works

The image is a plain SVG string: a solid rectangle plus a centered text label, sized to fit the smaller of width or height. Colors must be hex (#rgb or #rrggbb); the label is XML-escaped so it can never break the markup it is embedded in.

The data URI below is the same SVG, percent-encoded so it can be dropped directly into an <img src> or a CSS background-image with no file to upload anywhere.

Frequently asked questions

Why SVG instead of a rasterized PNG or JPEG?

An SVG placeholder scales to any size with no blur, and it can be built as pure text — no image-encoding library, and no binary dependency shipped to your browser. That matches every other tool on this site: nothing here processes actual image bytes.

What is the data URI for?

It drops straight into an <img src="..."> attribute, or a CSS background-image, with no separate file to host or upload — the whole placeholder travels as one self-contained string.

Why is there a size cap?

Width and height are capped at 10,000 to keep the generated SVG string — and the data URI built from it — a sane size. Nothing about a placeholder image needs to be larger than that, and without a cap a typo could ask for something absurd.