Simple, fast, and free avatar API for your applications.
MyAvatar provides a simple HTTP API to generate consistent avatars based on email addresses. It's a drop-in replacement for Gravatar.
hash: The MD5 hash of the lowercase, trimmed email address..svg: (Optional) .svg extension is supported.<img src="https://myavatar.onlc.eu/avatar/205e460b479e2e5b48aec07710c08d50" alt="MyAvatar" />
$email = "[email protected]";
$hash = md5(strtolower(trim($email)));
$avatarUrl = "https://myavatar.onlc.eu/avatar/" . $hash;
echo '<img src="' . $avatarUrl . '" />';
import md5 from 'md5'; // You need an MD5 library
const email = "[email protected]";
const hash = md5(email.trim().toLowerCase());
const avatarUrl = `https://myavatar.onlc.eu/avatar/${hash}`;
const img = document.createElement('img');
img.src = avatarUrl;
document.body.appendChild(img);
Avatars are cached by the browser for 1 hour and by our CDN for 1 month. They are generated as optimized SVGs for infinite scalability.