DiceBear – Open Source Avatar Library & API
What is DiceBear?
With DiceBear you can create awesome avatars for your project in no time. Whether you are looking for abstract shapes or lovingly designed characters, you will find something suitable among our avatar styles. And no matter how and for what you want to use the avatars, DiceBear offers the right solution!
In addition to purely random avatars, you can also create deterministic avatars for user identities. With the built-in PRNG you create the same avatar over and over again based on a seed. But also individual avatars are possible! Just use the countless options that each avatar style provides.
And thanks to the JavaScript library, HTTP API, CLI, Figma plugin, Editor and Playground, your next avatar is always just a stone's throw away! Explore our Avatar API for simple URL-based integration.
How to use?
HTTP API
Use a simple URL to embed avatars in any language or platform — no installation needed.
JS Library
Generate avatars in the browser or Node.js with full TypeScript support. Great for React, Vue, Svelte, and more.
CLI
Perfect for automations and batch exports in multiple image formats directly from the command line.
Designer
Use the interactive Editor to browse all avatar styles, customize options, and export avatars — no code required.
How does it work?
The avatars are created in SVG format. This allows to generate avatars dynamically without much computing power. In most cases, various SVG elements such as hair, eyes, ears etc. are selected from a set and combined to create a character / avatar.
XorShift32 is used as the algorithm for the PRNG. It is important to note that the PRNG does not attempt to be cryptographically secure.
Privacy-by-Design
DiceBear is built with privacy in mind. When using the JavaScript library, avatars are generated entirely on the client — no personal data ever leaves the user's device. For teams that require full control over data retention and infrastructure, DiceBear can be self-hosted — making it a privacy-focused avatar solution with no dependency on external services.