via.placeholder.com/avatar
Avatar placeholders
Give it a name, get initials on a colour that is always the same for that name. Or ask for abstract shapes, an identicon or a neutral silhouette. Never a human face.

Anna%20Svensson ?bg=1c1d19&fg=ecf34d&shape=rounded 
shapes/team-blue 
identicon/user-42 
default
URL syntax
https://via.placeholder.com/avatar/<name>[@2x][.<format>][?size=&shape=&style=&bg=&fg=&seed=&dpr=]
Every part is optional, and an avatar URL never returns an error: anything it can't make sense of becomes a sensible default.
| Part | Values | Default |
|---|---|---|
| name | URL-encoded full name: Anna%20Svensson → AS. +, _, and hyphenated or dotted slugs (anna-svensson, anna.svensson) also separate words. An e-mail address uses its local part. Also ?name=. Unicode-aware; CJK names get one character. | silhouette |
| format | .png, .svg, .webp, .jpg, .gif, .avif (or ?format=). AVIF keeps the transparent corners. Other image extensions get a PNG. | png |
size | 16 to 512 px, clamped. Also ?s=, or a path segment: /avatar/128/Anna%20Svensson. | 128 |
| scale | @1x to @3x (also @1.5x) at the end of any segment, or ?dpr=1 to 3. See Retina. | 1 |
shape | circle, square, rounded. JPEG and GIF have no transparency, so the corners are white there. | circle |
style | initials, shapes, identicon, silhouette. Also as a path segment: /avatar/identicon/<seed>. | initials for names |
bg, fg | 3 or 6 digit hex (with or without #, URL-encoded as %23) or a CSS colour name. Without fg, initials are white or near-black, whichever contrasts better. | from the seed |
seed | Any string. Picks the colours and pattern. Use a stable ID so two people with the same name look different. | the name as written in the URL |
Examples
https://via.placeholder.com/avatar/Anna%20Svensson.pnginitials AS, 128 px circlehttps://via.placeholder.com/avatar/anna-svensson.svg?size=64slug form, SVG, 64 pxhttps://via.placeholder.com/avatar/Anna%20Svensson.png?seed=user-1842colours tied to your own user IDhttps://via.placeholder.com/avatar/Anna%20Svensson.png?bg=1c1d19&fg=ecf34d&shape=roundedbrand colours, rounded squarehttps://via.placeholder.com/avatar/128/Anna%20Svensson.webpsize as a path segment, WebPhttps://via.placeholder.com/avatar?name=Anna+Svensson&size=48name as a query parameterhttps://via.placeholder.com/avatar/identicon/user-42.pngidenticon: mirrored 5 × 5 gridhttps://via.placeholder.com/avatar/shapes/team-blue.svgabstract shapeshttps://via.placeholder.com/avatar/default.pngneutral silhouette (alsouser,anonymous,undefined, …)https://via.placeholder.com/avatar/Anna%20Svensson.avifAVIF, transparent cornershttps://via.placeholder.com/avatar/%E6%9D%8E%E5%B0%8F%E9%BE%99.png李小龙 → 李
Retina: @2x and @3x
A scale multiplies the pixel size and keeps the drawing identical, just sharper:
https://via.placeholder.com/avatar/Anna%[email protected]256 × 256 (default 128, doubled)https://via.placeholder.com/avatar/64@2x/Anna%20Svensson128 × 128: the suffix can go on the size segmenthttps://via.placeholder.com/avatar/Anna%20Svensson.png?size=64&dpr=3192 × 192 via?dpr
<img src="https://via.placeholder.com/avatar/Anna%20Svensson.png?size=48"
srcset="https://via.placeholder.com/avatar/Anna%20Svensson.png?size=48&dpr=2 2x"
width="48" height="48" alt="Anna Svensson">
- The suffix wins over
?dpr. The output is capped at 512 px, so?size=256&dpr=3is 512 × 512. - E-mail addresses are safe:
/avatar/[email protected]is a name, because only a trailing@<n>xcounts as a scale.
URLs that look like guesses
AI tools and old templates often write avatar URLs that describe a person instead of naming one. Those get something neutral, never a face:
- Descriptor slugs such as
/avatar/woman-40s-smiling, or IDs such as/avatar/u/42and/avatar/women/44, get abstractshapesseeded by the slug. - Generic words (
default,user,avatar,undefined,null, …) get the silhouette. - Style names other services use map to the closest style:
mp,mmandperson→ silhouette;pixel,retroandblocks→ identicon;geometric,abstract,bauhaus,marble,beamandrings→ shapes. Face styles are treated as automatic. - Parameter aliases from other services work:
s,wfor size;u,id,hash,emailfor seed;background,colorfor colours;rounded=falseorradius=0for a square.
With synthetic people
Every persona and mock API user comes with a matching avatar URL, seeded by the persona ID:
"avatar_url": "https://via.placeholder.com/avatar/Magnus%20Magnusson.png?seed=se-1"
Determinism and headers
- Same URL, same bytes. The design is versioned (v1); a new look would be a new version.
- Headers as for images:
X-Placeholder: via.placeholder.com, cached for a year, CORS open. SVG avatars have a script-blockingContent-Security-Policyand anaria-label. - Every avatar file carries an embedded marker: the text
Placeholder image from via.placeholder.com - replace before shippingin PNG/JPEG/GIF/WebP/AVIF metadata, or a comment plusdata-placeholderattribute in SVG. Downloaded copies are still caught by placeholder-check.