Last reviewed:
What is a meta tag?
Meta tags are elements in a page's <head> that describe the page instead of displaying content. Browsers, search engines and social networks read them before they read anything else. A handful matter for almost every page. <meta charset="utf-8"> tells the browser how to decode the bytes, and the viewport tag makes the layout adapt to phone screens. The <title> element (not technically a meta tag) and <meta name="description"> are used by search engines as the usual source of the clickable headline and snippet. <link rel="canonical"> names the preferred URL when the same content is reachable at several addresses. <meta name="robots"> can ask search engines not to index a page or not to follow its links.
Social platforms use a separate vocabulary. The Open Graph protocol, created by Facebook and now read by LinkedIn, Slack, Discord, WhatsApp and many others, uses og:title, og:description, og:url and og:image to build link previews. X (formerly Twitter) reads twitter:card to choose between a small or large image preview, and falls back to the Open Graph values for anything it does not find under twitter:.
None of these tags guarantees how a page appears. Google may rewrite a title or pick a description from the page text if it thinks that matches the search better, and it ignores <meta name="keywords"> completely. Good tags still matter: they are the strongest suggestion you can give, and they control what people see when your link is shared.
How to use this tool
- Enter the page Title. The counter turns from green to amber after 60 characters and red after 70, a rough guide to where search results start cutting titles off.
- Write a Description of one or two sentences. Its counter turns amber after 160 characters and red after 200.
- Add the Canonical URL, the full address you want search engines to treat as the original, ideally the same URL as the page itself.
- Optionally fill in Keywords and Author, choose whether search engines may index the page and follow its links, and set the Language code (
enby default). - Add a Social share image URL for link previews and tick or untick charset and viewport, Open Graph and Twitter tags and theme-color (with its colour picker).
- Check the Google preview, which shows the site name, the URL as a breadcrumb, your title and the description cut to about 160 characters.
- Click Copy and paste the HTML into your page's
<head>. Sample fills the form with an example and Clear empties the text fields.
Examples
A product category page with a share image
Title Handmade Oak Desks - Built to Order | Northwood Studio (54 characters), a 146-character description, canonical URL https://northwood.example/desks/ and an image URL. The output:
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Handmade Oak Desks - Built to Order | Northwood Studio</title>
<meta name="description" content="Solid oak desks made to your measurements in our Bristol workshop. Choose the size, finish and drawers, and get free UK delivery within six weeks.">
<link rel="canonical" href="https://northwood.example/desks/">
<meta http-equiv="content-language" content="en">
<!-- Open Graph -->
<meta property="og:type" content="website">
<meta property="og:title" content="Handmade Oak Desks - Built to Order | Northwood Studio">
<meta property="og:description" content="Solid oak desks made to your measurements in our Bristol workshop. Choose the size, finish and drawers, and get free UK delivery within six weeks.">
<meta property="og:url" content="https://northwood.example/desks/">
<meta property="og:image" content="https://northwood.example/img/oak-desk-1200x630.jpg">
<!-- Twitter -->
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:title" content="Handmade Oak Desks - Built to Order | Northwood Studio">
<meta name="twitter:description" content="Solid oak desks made to your measurements in our Bristol workshop. Choose the size, finish and drawers, and get free UK delivery within six weeks.">
<meta name="twitter:image" content="https://northwood.example/img/oak-desk-1200x630.jpg">
Because an image is set, the Twitter card type is summary_large_image; without one it is summary. No robots tag is written, because indexing and following links are what search engines do by default.
A page that should stay out of search, with special characters
Title Q&A: "Tabs vs spaces" <survey results>, Not index this page selected, the language field emptied, and the charset and social options unticked:
<title>Q&A: "Tabs vs spaces" <survey results></title>
<meta name="robots" content="noindex, follow">
Ampersands, quotes and < are escaped so they cannot break the markup. noindex, follow keeps the page out of results while still letting crawlers follow its links.
Common errors and how to fix them
- Changes do not show in Google. Search engines only see new tags after recrawling the page, which can take days or weeks. In Google Search Console, the URL Inspection tool lets you request a recrawl.
- Google shows a different title or snippet. It rewrites titles that are very long, stuffed with keywords or unlike the page content, and may build snippets from body text. Make the title a plain, accurate description of the page and keep it close to the main heading.
- Old or missing image in a Slack or LinkedIn preview. Platforms cache previews. Use the platform's debugging tool to refresh it (LinkedIn Post Inspector, Facebook Sharing Debugger), and make sure the image URL is absolute, public and not blocked by
robots.txtor a login. - Relative URLs.
og:imageand canonical values like/img/a.jpgare unreliable. Always use fullhttps://URLs. - Canonical pointing to the wrong page. Templates often copy one canonical onto every page, which tells search engines all pages are duplicates of one. Each page should point to its own preferred URL.
- Page accidentally removed from search. A
noindexcopied from a staging template is a common cause. Check the generated robots tag before going live.
When developers use this
- Setting up the
<head>template for a new site or a framework layout file. - Adding social preview tags to a landing page or blog post before it is shared.
- Auditing an existing page: re-entering its title and description to check their length against the preview.
- Marking a staging, search-results or thank-you page as
noindex. - Writing the description for a documentation or release notes page, where the snippet decides whether people click.
Privacy and how it works
The tags and the preview are generated by JavaScript in your browser as you type. Nothing is sent to a server, and no page is fetched, so you can draft tags for pages that have not launched yet without revealing the URL or product name.
Limitations
- The search preview is an approximation. Google truncates by pixel width rather than a fixed number of characters, and its layout changes over time.
- Google ignores the
keywordsmeta tag and does not usehttp-equiv="content-language"to detect language. Set<html lang="…">on the page, and usehreflanglinks for translated versions. - The output covers common tags only. It does not generate structured data (JSON-LD), favicons,
hreflanglinks or platform-specific tags such asog:locale.
FAQ
How long should a title tag be?
There is no fixed limit, but Google typically shows about 50-60 characters on desktop before cutting the title off. Put the most important words first and keep the brand at the end, so truncation removes the least useful part.
How long should a meta description be?
Aim for roughly 120-160 characters: long enough to describe the page, short enough to show in full on most results. Each page should have its own description; duplicates across many pages are often ignored.
Do meta keywords help SEO?
No. Google said in 2009 that it does not use the keywords tag for ranking, and Bing has warned that stuffing it can look like spam. Leave it empty unless your own site search reads it.
What size should the social share image be?
1200 × 630 pixels (a 1.91:1 ratio) works well for Open Graph and large Twitter cards. Keep important text away from the edges, because some platforms crop the image to a square.
Do I need both Open Graph and Twitter tags?
Not strictly. X falls back to Open Graph values, but it needs twitter:card to choose a large image layout. The tool writes both so previews are consistent everywhere.
Should the canonical URL point to the page itself?
Usually yes. A self-referencing canonical tells search engines which version to use when the URL also appears with tracking parameters, a different case or a trailing slash variant. Point it elsewhere only when the page really is a duplicate of another URL.
Does noindex remove a page that is already in Google?
Yes, once Google recrawls the page and sees the tag. Do not also block the page in robots.txt, or the crawler cannot see the noindex.