Meta
Metadata found in the <head> of an HTML page is a form of SEO that allows Rich previews
<!DOCTYPE html><head> <meta charset="UTF-8"/>
<!-- Text meta tags --> <title>Stephcraft's Website</title>
<!-- Color meta tags --> <meta name="color-scheme" content="dark light"/> <meta name="theme-color" content="#4286f4"> Color meta tags
<meta name="color-scheme"/> Light and Dark mode support and preference
- A list of supported modes
light dark separated by spaces
- The order determines the prefered mode
<meta name="theme-color"/> The Theme color associated with the page
- Shown in Rich previews on Discord
- A theme color can be associated per mode with
media
<!-- Open Graph meta tags --> <meta property="og:site_name" content="Stephcraft"/> <meta property="og:title" content="Home Page"/> <meta property="og:description" content="..."/> <meta property="og:url" content="https://stephcraft.net"/> <meta property="og:image" content="https://stephcraft.net/cover.png"/> โ Open Graph meta tags shown in Rich previews
og:site_name The Name of the website
โ Must be identical across all pages
og:title The Title of the url
โ Recommended limit is 60 characters
og:description The Description of the url
โ Recommended limit is 200 characters
og:url The canonical url
โ Same as <link rel="canonical"/>
og:image An image url
โ Recommended size is 1200 ร 630
Optional Open Graph properties โ 29 collapsed lines
<meta property="og:determiner" content="the"/> The word prefix that appears before the title:
a an the
"" default
auto dynamic
<meta property="og:locale" content="en_US"/> <meta property="og:locale:alternate" content="fr_FR"/> <meta property="og:locale:alternate" content="es_ES"/> ... โThe languages supported
og:locale The locale the Open Graph meta tags are marked up in
og:locale:alternate Other locales available for this page
Defaults to en_US
<meta property="og:video" content="https://stephcraft.net/trailer.mp4"/> <meta property="og:audio" content="https://stephcraft.net/theme.mp3"/> โAdditional Media
og:video A video url
og:audio An audio url
<!-- Optional Image properties --> <meta property="og:image" content="https://stephcraft.net/cover.png"/> <meta property="og:image:secure_url" content="https://stephcraft.net/cover.png"/> <meta property="og:image:type" content="image/png"/> <meta property="og:image:width" content="1200"/> <meta property="og:image:height" content="630"/> <meta property="og:image:alt" content="A cup containing blue liquid"/>
<!-- Optional Video properties --> <meta property="og:video" content="https://stephcraft.net/trailer.mp4"/> <meta property="og:video:secure_url" content="https://stephcraft.net/trailer.mp4"/> <meta property="og:video:type" content="video/mp4"/> <meta property="og:video:width" content="1200"/> <meta property="og:video:height" content="630"/>
<!-- Optional Audio properties --> <meta property="og:audio" content="https://stephcraft.net/theme.mp3"/> <meta property="og:audio:secure_url" content="https://stephcraft.net/theme.mp3"/> <meta property="og:audio:type" content="audio/mpeg"/>
<meta property="og:type" content="article"/> Can be one of:
-
website default
-
article
-
profile
-
book
-
payment.link
-
music.song music.album music.playlist music.radio_station
-
video.movie video.episode video.tv_show video.other
Limited support
Technical meta tags โ 4 collapsed lines
<!-- Technical meta tags --> <meta name="robots" content="all"> <meta name="rating" content="adult"> <meta name="generator" content="..."/> Technical meta tags
<meta name="robots"/> List of crawler permissions separated by spaces
ยท
index noindex allow or deny page indexing
follow nofollow allow or deny crawling links on this page
all none shortcut for both page indexing and link crawling permissions
nosnippet Do not show a text snippet or video preview in search results
noimageindex Deny image indexing on this page
notranslate Don't offer Google Translate translation of this page in search results
max-snippet:# Character limit for text snippets in search results
max-video-preview:# Duration limit (in seconds) for video snippets in search results
max-image-preview:# One of none standard large for image previews in search results
unavailable_after:# Date after which the page is hidden from search results
- Equivalent to
X-Robots-Tag HTTP Header
- Alternatively, use robots.txt
<meta name="rating"/> Whether the page is available with SafeSearch
<meta name="generator"/> The framework used for the frontend
Deprecated meta tags โ 4 collapsed lines
<!-- Deprecated meta tags --> <meta name="title" content="..."/> <meta name="author" content="..."/>
<!-- Link tags --> <link rel="icon" href="favicon.svg"/> <link rel="canonical" href="https://stephcraft.net"/> <link rel="alternate" hreflang="fr" href="/fr/home"/> <link rel="alternate" hreflang="es" href="/es/home"/> ... โ Link tags
<link rel="icon"/>
The icon of the page
<link rel="canonical"/> The preferred url for the page
- Uniquely identifies urls against:
- Case sensitivity
- Fragments
- Search params
- Redirects
- Subdomain duplication
- Trailing slashes
- File names
- Protocols
<link rel="alternate"/> Translated page variants
hreflang Must be in en or en-US format
- Alternatively, use the Localization Sitemap Extension
Deprecated link tags โ 2 collapsed lines
<!-- Deprecated link tags -->
<!-- Schema Markup --></head><body>...</body></html>Tools
Open Graph Link Previews
Open Graph Generator
Facebook Link Preview
Resources
MDN Web Docs โ Meta
MDN Web Docs โ Meta properties
Google Search Central โ Meta tags
MDN Web Docs โ Link
Frameworks
Astro Docs โ Metadata
Next.js Docs โ Metadata
TanStack Start Docs โ Metadata