Utvikling · verktøy

Generator for metatagger og Open Graph

Oppgi sidemetadata og en offentlig bilde-URL for å lage tagger og kontrollere tegnlengdene.

Kjøres i nettleseren. Ingen opplasting.

Values are processed locally in this browser.

Result

—

Om verktøyet

Generator for metatagger og Open Graph sem complicação.

Sosiale plattformer kan ignorere eller beskjære tagger. Bruk en canonical-URL du kontrollerer, og sørg for at forhåndsvisningsbildet er offentlig og har riktig størrelse.

Veiledning

Slik bruker du Generator for metatagger og Open Graph

The Meta Tag and Open Graph Generator turns a page title, a short description and a web address into a block of HTML tags for the head of a page. It writes the title, description, canonical link, Open Graph tags and Twitter card tags, plus a comment that counts the characters in your title and description. It does not open your live page, check that an image loads, or promise how a search engine or social site will show your link.

Slik gjør du

  1. Type the page title and a description of the page. Both are needed. The title can have up to 200 characters and the description up to 500.
  2. Enter the canonical URL as a full address that starts with http:// or https://. This is the address you want treated as the main home of the page.
  3. If you want, add a public image address and a site name. Change the locale code from en_US when the page uses another language or region.
  4. Press Calculate, read the character counts on the first line, then copy the result and paste it between the head tags of your page.

Eksempler

A page with no social image

Du skriver inn
Tittel
Blue Ceramic Mugs | Hearth Studio
Beskrivelse
Spar på leker <i dag>.
URL
https://example.com/mugs
Bilde
Nettstedsnavn
Hearth Studio
Lokalinnstilling
en_US
Du får
Første linje
<!-- 33 title characters · 67 description characters -->
Canonical-lenke
https://example.com/sale?a=1&amp;b=2
Twitter-kort
summary
og:image-linje
not written

The first line counts 33 characters in the title and 67 in the description. With no image address the tool writes a summary card and leaves out every image line. It also writes og:type as website, plus og:title, og:description, og:url, og:site_name and og:locale.

Kjørt med verktøyets egen kode.

Special characters and a social image

Du skriver inn
Tittel
Spring Sale: Tom & Jerry's "Best" Toys
Beskrivelse
Save on toys <today>.
URL
https://example.com/sale?a=1&b=2
Bilde
https://example.com/img/sale.jpg
Lokalinnstilling
en_GB
Du får
Tittel
<title>Spring Sale: Tom &amp; Jerry&apos;s &quot;Best&quot; Toys</title>
Beskrivelse
<meta name="description" content="Save on toys &lt;today&gt;.">
Canonical-lenke
https://example.com/sale?a=1&amp;b=2
Twitter-kort
summary_large_image
og:image
https://example.com/img/sale.jpg

Ampersands, quotes, apostrophes and angle brackets are swapped for HTML entities so the tags stay valid. Adding an image address switches the card type to summary_large_image and adds og:image and twitter:image lines.

Kjørt med verktøyets egen kode.

An address with no https

Du skriver inn
Tittel
Home
Beskrivelse
Hi
URL
example.com
Du får
Melding
Canonical must be a complete URL.

The canonical address must be complete, with http:// or https:// at the start. The same check applies to the image address, and addresses with a username or password in them are refused.

Kjørt med verktøyets egen kode.

Når det er nyttig

  • Draft the head tags for a new landing page, blog post or product page before it goes live.
  • Add share tags to a hand-written static site that has no SEO plugin.
  • Compare two wordings of a title or description by their character counts.
  • Check that a canonical address and an image address were typed in full before you paste them into a template.

Begrensninger

  • The title must be 1 to 200 characters and the description 1 to 500. The counts are only shown for your information; no ideal length is enforced.
  • The output always uses og:type website, so it does not suit article, product or video pages without a hand edit. It does not add image width or height, a robots tag, a charset or a viewport tag.
  • The Twitter lines are written with the property attribute. Many sites write them with name instead, so check how your target platform reads them.
  • The tool never fetches your page or image. It cannot tell whether the image is public, the right size, or whether a social site will crop it.

Tips

  • Write the description for a person reading a result list first. Search engines may replace it with text taken from the page.
  • Use a full web address for the image, and open it in a private browser window to see that it loads without a login.
  • Delete the counting comment on the first line if you do not want it in the source of your page.

Kilder

Vanlige spørsmål

Sobre Generator for metatagger og Open Graph.

Where do I paste the generated tags?

Paste them between the opening and closing head tags of your HTML file. In a content system, look for a field for custom head code. Afterwards check that the page does not end up with two title tags or two descriptions.

How long should a title and description be?

The tool only counts characters and does not set a target. Google says a meta description has no length limit, but the snippet is cut to fit the device width. Keep the key words near the start of each text.

Why is there no og:image line in my result?

The image box is optional, so the tool writes image lines only when you fill it in. The Open Graph protocol lists og:image among four required properties, so add a public image address if you want complete markup.

Will Google show my meta description?

Not always. Google says it mostly builds a snippet from the content of the page, and may use the meta description when it describes the page better than the text on the page does.

What does the canonical link do?

The canonical link names the address you prefer when the same page can be reached through several addresses. The tool uses the same address for og:url. Pick an address you control that really loads.

Why were my quotes and ampersands changed?

Characters that have a special meaning in HTML are written as entities, such as &amp; for an ampersand and &quot; for a double quote. Browsers turn them back into the normal characters, so visitors see your original words.

Is my text sent to a server?

No. The page says the values are processed locally in your browser. The tool only reads the web addresses you type and never opens them, so nothing is requested from your site or image host.

Hvordan bruker du Metatagg-generator?

Oppgi sidemetadata og en offentlig bilde-URL for å lage tagger og kontrollere tegnlengdene.

Lastes dataene mine opp til en server?

Nei. Behandlingen skjer i nettleseren din, og opplysningene dine lastes ikke opp.