Twitter Card Generator
Generate the meta tags that control how your links look when shared on X (Twitter).
Twitter Card Generator
Twitter Cards, now called X Cards, are meta tags in the <head> of a page that control how a link looks when someone posts it on X: the image, the title and the description. Fill in your page title, description, image URL and username, click Generate, and you get the tags ready to paste into your page. The generator builds a large image card (summary_large_image), the card type most sites use for articles, products and landing pages.
How to use Twitter Card Generator
- Enter the Site Title, ideally the title of the page you are tagging.
- Enter your X Username, with or without the @. It is optional.
- Enter the full Image URL, starting with https://.
- Write a short Description of the page.
- Click Generate, copy the tags and paste them inside the
<head>of the page.
Example
For a blog post, the result looks like this:
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:site" content="@yourbrand">
<meta name="twitter:title" content="How to Compress Images for the Web">
<meta name="twitter:description" content="Smaller images, faster pages: formats, sizes and settings.">
<meta name="twitter:image" content="https://example.com/images/compress-guide.jpg">
Quotes and angle brackets in your text are escaped, so a title like The "Best" Tools does not break the tag.
Which tags X needs
twitter:card is the only tag X really needs from this list, because it has no Open Graph equivalent. For the title, description and image, X falls back to the Open Graph tags (og:title, og:description, og:image) when the Twitter versions are missing. If your page already has Open Graph tags, adding twitter:card is often enough; if it has none, add both sets so Facebook, LinkedIn and messaging apps show a good preview too. The SEO Tags Generator creates the Open Graph tags.
Choosing the image
- Large image cards use a 2:1 ratio. 1200 × 600 pixels fits exactly; a 1200 × 630 Open Graph image also works and is cropped slightly.
- X accepts JPG, PNG, WebP and GIF (only the first frame of an animated GIF is used) up to 5 MB.
- Use a full, public URL. Images behind a login, or blocked for X's crawler in robots.txt, do not show.
- Keep important text away from the edges, and remember that X shows large cards with your domain over the image, so the picture has to carry the message.
To get the image to the right size, use the Image Cropper or the Image Resizer.
Testing your card
X's Card Validator no longer shows a preview. To check a card, paste the link into a new post on X and look at the preview before you post, or run the page through the Open Graph Checker, which reads the Twitter and Open Graph tags the way social networks do. X keeps card data for a while, so a change to an image or title may not appear on a link that was shared before.
Frequently asked questions
What image size works best?
Do I need an X account?
twitter:site tag, which links the card to your account. Leave it empty and the tag is left out; the card still works.Do Twitter Cards help SEO?
Why does my old preview still show?
?v=2 to the link makes X fetch it fresh.Where do the tags go in WordPress?
Related guides
-
On-Page SEO Checklist: 15 Things to Check Before You Hit Publish
A practical, no-jargon checklist for getting a single page right: titles, descriptions, headings, images, links, indexing and structured data.
-
Schema Markup for Beginners: What JSON-LD Does and Which Types to Use
A beginner-friendly explanation of structured data and JSON-LD, the schema types most sites need, and how to add and test them.
-
301 vs 302 Redirects: Which One to Use, and How to Check Them
The difference between permanent and temporary redirects, how each affects SEO, common redirect mistakes, and how to set up and test them.