Web & HTML

OG Tag Generator

Generate Open Graph and Twitter Card meta tags for social media sharing. Preview how your page looks when shared on Facebook, Twitter/X, and LinkedIn.

Free Client-Side No Sign-Up Nothing Stored
Social Share Preview
Image preview (paste image URL above)
yoursite.com
Your Page Title
Your page description
Generated HTML

What This Tool Does

Generates the Open Graph and Twitter Card meta tags that control how your page appears when shared on social media. Fill in the fields, see a live preview of your social share card, and copy the ready-to-paste HTML. Tags update live as you type.

Frequently Asked Questions

What are Open Graph tags?
Open Graph (OG) tags are meta tags that control how your page appears when shared on social media platforms like Facebook, LinkedIn, Pinterest, and Slack. Without them, social platforms guess at the title, image, and description — often with poor results.
What size should my og:image be?
The recommended size is 1200×630 pixels with an aspect ratio of 1.91:1. Images smaller than 600×315 may not display as a large card preview. Facebook, Twitter, and LinkedIn all use similar dimensions.
What is the difference between og:url and the canonical URL?
og:url tells social platforms the canonical URL to use for share counts and attribution. It should match your canonical link tag. Using different values can split your share counts across URLs.
Do I need both Open Graph and Twitter tags?
Twitter falls back to Open Graph tags if Twitter-specific tags are absent, so in many cases you only need OG tags. However, Twitter Card tags (especially twitter:card) give you more control over how your content is displayed on Twitter/X specifically.