What Is DiceBear?
Updated
DiceBear is a free, open source avatar library and API that generates deterministic SVG profile pictures from a seed string. You give it any text — a username, email, or ID — and it returns the same avatar every time, across every platform. It ships with 61 styles and client libraries for JavaScript, PHP, Python, Rust, Go, Dart, and C#, plus a CLI. It fits projects that need placeholder or user avatars without storing image files or sending user data to a third party, and because it is self-hostable, it also fits privacy-sensitive deployments.
How deterministic avatars work
The core mechanism is the seed. DiceBear hashes your seed string and uses the result to pick the combination of features (hair, eyes, colors, accessories, and so on) that make up the avatar. The same seed always produces the same avatar, so you never need to save the generated image — you can regenerate it on demand from the user's existing identifier.
The simplest form is an HTTP request:
https://api.dicebear.com/10.x/lorelei/svg?seed=Felix
Change lorelei to any other style name, and change Felix to your own seed. The response is an SVG, which scales cleanly and stays small.
If you would rather generate avatars in your own code, the same idea applies through the libraries. In JavaScript:
import { Style, Avatar } from '@dicebear/core';
import definition from '@dicebear/styles/lorelei.json' with { type: 'json' };
const style = new Style(definition);
const avatar = new Avatar(style, { seed: 'Felix' });
Equivalent packages exist for Python, Rust, Go, Dart, and C#, and there is a CLI (npx dicebear lorelei --seed 'Felix') for generating avatars without writing application code.
The 61 styles
Styles range from hand-drawn characters to abstract patterns, pixel art, and detailed illustrations. Some are original DiceBear designs; others come from independent artists and carry their own licenses — for example, the Lorelei style is a remix of work by Lisa Wischofsky licensed under CC0 1.0. Style names you will see include adventurer, adventurer-neutral, avataaars, avataaars-neutral, and lorelei, among many others.
Because each style has its own visual character and licensing, check the individual style page before using it in a commercial product.
Where DiceBear fits
| Use case | Why it works |
|---|---|
| User profile pictures | Generate from a username or user ID; no upload or storage needed |
| Placeholder avatars | Consistent, recognizable images for seeded or demo accounts |
| Apps and websites | SVG output scales to any size; libraries integrate directly |
| Privacy-sensitive projects | Self-host the API so no data leaves your infrastructure |
The deterministic property is what makes it practical: you can treat an avatar as a pure function of a user identifier rather than a stored asset.
Getting started
- Open the Playground to preview styles and try seeds interactively.
- Pick a style that matches your product's visual tone.
- Either call the HTTP API with your seed, or install the library for your language and generate avatars locally.
- If you need full control over data, self-host the API instead of calling the public endpoint.
The main things to verify before committing are the license of your chosen style and whether you want to depend on the hosted API or run your own instance.