Template

Twitter (X) card image template

This Twitter card template makes the 1200 by 675 images that fill the timeline at a 16 by 9 ratio: a launch announcement with an app window, a review quote and a milestone number.

Each card is HTML in your repo, so making the next one means copying a file and changing the text.

X card announcing "Lumen 2.0" with a desktop window showing the app

OG image guide Twitter card source on GitHub

Why 1200 by 675

X crops single images in the timeline to 16 by 9 on most clients. A 1200 by 675 image shows in full without the top and bottom being cut, while a 1200 by 630 OG image gets small bars or a crop.

For link previews, X reads your og:image or twitter:image tag. Use the OG template for those and this one for images you attach to posts.

Three posts that come up again and again

Launches, reviews and milestones are the posts most indie apps make every month. The launch card shows the product. The quote card turns a real review into social proof; only use reviews you have permission to share. The milestone card is one big number and a line of context.

Because the cards share a stylesheet, a month of posts looks like one set.

Text that survives the timeline

People scroll past at speed, so keep the headline above 50 pixels and under ten words. Leave the bottom right clear if you post with alt text badges or video controls. Export at 2x if the card holds small UI text, since X recompresses uploads and fine detail is the first thing to blur.

Agent prompt

Using Open Assets (npx open-assets), add a twitter-card collection to assets.json with sourceSize 1200x675 and the twitter-card export. Create three HTML cards in assets/twitter/: a launch card with my app window, a review quote card and a milestone card with one large number. Share brand colors with my other templates. Render with npx open-assets render.

assets.json collection

{
  "id": "twitter-card",
  "label": "X / Twitter card",
  "sourceSize": {
    "width": 1200,
    "height": 675
  },
  "templates": [
    {
      "src": "assets/twitter/01-launch.html",
      "name": "01-launch"
    },
    {
      "src": "assets/twitter/02-quote.html",
      "name": "02-quote"
    },
    {
      "src": "assets/twitter/03-milestone.html",
      "name": "03-milestone"
    }
  ],
  "export": [
    {
      "name": "twitter-card",
      "size": {
        "width": 1200,
        "height": 675
      }
    }
  ]
}

Sizes it renders

PlatformSizePixelsName in assets.jsonCopy
WebX / Twitter card1200 × 675twitter-card
WebOG image1200 × 630og

FAQ

Frequently asked questions

What is the best image size for X (Twitter) posts?

1200 by 675 pixels, a 16 by 9 ratio, shows uncropped in the timeline on most clients.

What size is a Twitter summary_large_image card?

X recommends an aspect ratio of about 2 to 1. A 1200 by 630 OG image works for link cards.

Can I schedule posts with these images?

Open Assets only renders the images. Attach them in X or any scheduling tool.

Can I make a card per release automatically?

Yes. Drive the text from a JSON file or localizations.json and render in CI after each release tag.