Why you’re getting a small card
Mastodon picks the card layout based on image aspect ratio, not a meta tag:
- Width > height (landscape) = large card with a full-width image
- Width <= height (portrait or square) = small card with a 120px thumbnail
twitter:card is completely ignored. Setting it to summary_large_image does nothing on Mastodon.
Common scenarios
- 1080 x 1080 (square): small thumbnail
- 1080 x 1350 (portrait): small thumbnail
- 630 x 630 (square): small thumbnail
- 1200 x 630 (landscape): large card
- 640 x 360 (landscape): large card
The rule is simple: width must be strictly greater than height.
The fix
Use a landscape image:
<meta property="og:image" content="https://example.com/og-image-1200x630.jpg">
1200 x 630 pixels (1.91:1) works across Mastodon, Twitter, Facebook, and most other platforms.
Different images per platform
Mastodon only reads og:image and ignores twitter:image. If you need a square or portrait image for other platforms, your options are:
- Use a landscape image universally, which is safest and works everywhere
- Serve a different
og:imagebased on user agent detection (match on theMastodon/prefix), which works but adds complexity and fragility
Testing your fix
Post the URL on a Mastodon instance. If the URL was already shared on that instance, the old card is cached for 14 days. Use a different instance or append ?v=2 to test with a clean cache.