Gravatar URL Builder

Build a Gravatar avatar URL from an email address.

Open tool

Overview

The Gravatar URL Builder converts an email address into the canonical Gravatar image URL so you can drop a globally-recognised avatar into a profile card, comment thread or admin dashboard without writing the hashing code yourself. Set the size, choose a fallback style and pick a rating, and the tool emits a ready-to-paste URL plus an <img> snippet.

The builder is aimed at indie developers wiring up account pages, designers prototyping user lists and marketing teams composing rich emails with consistent avatars. Long-tail searches like "generate gravatar url from email", "gravatar default image identicon" and "gravatar size 200 retina avatar" all land here.

How it works

Gravatar identifies users by the MD5 (legacy) or SHA-256 (modern) hash of their lower-cased, trimmed email address. The tool normalises your input — trim whitespace, lower-case the entire string — then computes both hashes and embeds the chosen one in the URL https://www.gravatar.com/avatar/<hash>. Query parameters control rendering: s sets the pixel size from 1 to 2048, d picks the fallback (mp, identicon, monsterid, wavatar, retro, robohash, blank or a custom URL) and r filters by rating (g, pg, r, x).

The builder does not contact Gravatar; everything is computed locally. Hashing the email in the browser also means the address is never logged by any intermediate server, which is useful when you need to look up an avatar without revealing the customer's email.

Examples

ada@example.com → https://www.gravatar.com/avatar/cf3c... (SHA-256)
Size 200, fallback identicon → ?s=200&d=identicon
Force PG-rated, retina-sized → ?s=400&r=pg
Custom fallback image → ?d=https%3A%2F%2Fexample.com%2Fdefault.png

FAQ

Should I use MD5 or SHA-256?

Gravatar still serves MD5 hashes for backwards compatibility, but new integrations should use SHA-256. The builder emits both so you can switch without re-hashing.

Does the email leave my browser?

No. The hash is computed locally and only the hex digest appears in the URL.

What size should I request?

Pick double the displayed pixel size to look crisp on retina screens. The maximum is 2048, but anything above 400 is usually overkill for an avatar.

What if the user has no Gravatar?

Choose a fallback style. identicon and retro produce a deterministic pattern from the hash, while mp (mystery person) shows a neutral silhouette.

Can I use a custom fallback image?

Yes. Set the d parameter to a fully-qualified HTTPS URL. The builder URL-encodes it for you.

Try Gravatar URL Builder

An unhandled error has occurred. Reload ×