Quick Start
Generate avatars instantly with a simple HTTP GET request. No authentication required.
https://exavatar.deno.dev/api/avatar API Endpoint
GET https://exavatar.deno.dev/api/avatar Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| set | string | random | Avatars Set Identifier |
| id | string | random | Avatar Identifier |
| size | number | 256 | Image size in pixels 1632641282565121024 |
| format | string | webp | Output format pngjpegwebp |
| color | string | random | Background color (CSS syntax) |
| text | string | Custom text overlay (2 chars) |
Examples
Random Avatar
https://exavatar.deno.dev/api/avatar Custom Set and Id
https://exavatar.deno.dev/api/avatar?set=animals&id=dinosaur Text Overlay
https://exavatar.deno.dev/api/avatar?text=JD&color=#00d4aa Integration Examples
HTML
<img src="https://exavatar.deno.dev/api/avatar" /> CSS
.avatar {
background-image: url('https://exavatar.deno.dev/api/avatar');
background-size: cover;
} JavaScript
const image = new Image(256, 256);
image.src = 'https://exavatar.deno.dev/api/avatar'; React
export const Avatar = () => (<img src="https://exavatar.deno.dev/api/avatar" />) Angular
@Component({
template: '<img src="https://exavatar.deno.dev/api/avatar" />'
})
export class Avatar { } Svelte
<script>
$: src = 'https://exavatar.deno.dev/api/avatar';
</script>
<img src={src} /> Astro
---
const src = 'https://exavatar.deno.dev/api/avatar';
---
<img src={src} /> Rate Limits
Currently, there are no rate limits imposed on the API. However, we recommend implementing client-side caching to improve performance and reduce unnecessary requests.
Support
Need help or have questions? Check out our interactive playground or visit our GitHub repository for more information.