SEO & web Meta tags

Meta tag generator

Built in your browser · nothing is uploaded

Local · a wrong canonical is worse than none

Generates the whole head block at once: title, description, canonical, Open Graph and the twitter: tags, with the card type set automatically from whether an image is supplied. Around 155 characters is the working limit for a description, and a robots directive of index, follow is the default and never worth writing out. Two more blocks sit behind the switcher at the top of the panel: the reciprocal rel="alternate" hreflang set for a page that exists in several languages, and the full X card with its own type, creator handle and image alt text.

How to use the meta tag generator

1 Pick the block across the top of the panel: the meta and Open Graph block it opens on, the hreflang set, or the X card.
2 Fill in the fields. Empty ones are left out, never emitted blank.
3 Give the canonical an absolute URL pointing at this page: a wrong one does more damage than none at all.
4 Add a social image at 1200 × 630 and the card type looks after itself.
5 For hreflang, list every language version including this one, then put the identical block on every page in the set.
6 Copy the block into the head, then check it by sharing the link from a private account before you publish.

Writing these by hand is where inconsistencies creep in: an og:title that drifted from the page title, a twitter:card set to summary while a large image is supplied, a canonical missing entirely. Generating them together keeps them in step.

Two of the fields are worth a note. The canonical must be an absolute URL and should be self-referential on a normal page, and omitting it entirely is safer than getting it wrong, since one pointing at the wrong page removes yours from the index. And a robots directive of index, follow is already the default behaviour, so writing it out achieves nothing; the tag is only worth including when you want noindex or nofollow.

Open Graph, and the one twitter: tag that matters

On the social side, X falls back to Open Graph for title, description and image, so duplicating those in twitter: tags is maintenance you can avoid and another place for two copies to drift apart. The exception is twitter:card itself: without it the default is the small summary card, which is far less prominent in a timeline than the large-image one. That is why it is emitted here automatically and set from whether an image is present, since summary_large_image with no image produces a broken card.

The combined block deliberately stops at twitter:site, because everything past it is card-specific: twitter:creator names the author’s account rather than the site’s, twitter:image:alt is the card’s alt text, and the card type is worth setting by hand when the automatic choice is not what you want. Those live in the X card block behind the switcher, which is the whole set of twitter: tags and nothing else — use it when you want that byline or that alt text, and the combined block otherwise. One tag genuinely is not generated anywhere here: og:image:alt, the Open Graph counterpart of the card’s alt text and a structured property of og:image. Write that one next to the image tag yourself. Card validation moved behind a login some years ago, so the practical test for any of it is posting the link from a private account and looking at it.

Language versions are a block of their own

They are the second thing this page builds, and the reason they are a separate block rather than more fields on the first one is the rule that breaks most setups. rel="alternate" hreflang tags have to be reciprocal: every page in the set lists every other page and itself, and the block is identical everywhere, or search engines discard the whole cluster and not just the one broken link. So it is a property of the set, not of a page — you list every version once, including the one you are on, and paste the identical lines into all of them. That is what the self-reference amounts to, and it is why there is nothing to adjust per page. The codes are ISO 639-1 for language then ISO 3166-1 alpha-2 for region, in that order, so en-GB and never en-uk, since the United Kingdom code is gb; a region on its own is never valid. x-default covers visitors whose language matches none of the versions. None of it replaces the canonical: each language version still needs one pointing at itself and not at another language, which is the first block on this page and not this one.

What people use it for

  • Writing a complete head block for a new page
  • Keeping og:title and the page title in step
  • Setting a self-referencing canonical
  • Adding a noindex directive to a page you want out of the index
  • Building the reciprocal hreflang block for a page in several languages
  • Adding an x-default for visitors whose language matches none of your versions
  • Checking which twitter: tags Open Graph already covers
  • Writing the X card by hand when you want a creator handle or image alt text
  • Getting a large-image card instead of the small summary one
  • Working out the right hreflang code for a language version

Questions

No. That is the default. The tag is only worth adding for noindex or nofollow.

The Open Graph protocolGoogle Search Central — meta tagsGoogle Search Central, localised versionsX — cards markup reference
Was this tool any good?
Internal signal only · I use it to find the tools worth rebuilding