X (Twitter)

X (Twitter) sizes, specs, and posting limits

X supports up to four photos, one video, or one GIF per post, but those media types cannot be mixed. The API does not require one fixed static-image resolution. PublishQ automatically resizes very high-resolution images to fit.

Updated July 2026

Recommended sizes

Good defaults for X (Twitter)

Use these sizes when you need a sensible default. The tables below cover the limits enforced by the API.

Landscape image

1600×900 (16:9)

A good timeline-friendly image size.

Landscape video

1280×720

The documented landscape video resolution.

Large images

Any resolution

PublishQ automatically resizes very high-resolution images to fit.

API limits

X (Twitter) API specifications

Check these values in your upload validator or before an agent submits a post.

Image, video, and GIF limits

Media limits for a single X post.

Photos
4 × JPEG, PNG, or WebP; 5 MB each
Video
1 × MP4 or MOV; 512 MB
Video duration
0.5–140 seconds
Video aspect ratio
Between 1:3 and 3:1
GIF
1 × 15 MB; 1280×1080; 350 frames

Text, poll, and rate limits

Copy and API constraints that commonly affect automated posts.

Post text
280 characters / 25,000 with Premium
Poll choices
2–4 options; 25 characters each
Poll duration
5 minutes to 7 days
API rate
200 posts / 15 min; 300 / 3 hours

Common publishing errors

X (Twitter) publishing errors

Find the returned code or the closest matching failure below, then fix the cause before retrying the post.

invalid-request (400)

The post body is malformed, has missing fields, or combines incompatible options.

Fix: Validate the JSON and send only one compatible post mode, such as media or a poll.

client-forbidden (403)

The app or access token cannot use the requested posting operation.

Fix: Check the app access tier, OAuth scopes, and user-context authentication.

usage-capped (429)

The project has exhausted its current X API usage allowance.

Fix: Wait for the usage window to reset or review the project’s API plan.

rate-limit-exceeded (429)

Too many requests were sent inside the endpoint’s rate window.

Fix: Read x-rate-limit-reset and retry after that time with backoff.

text-too-long (400)

The post exceeds the account’s text allowance after X applies weighted character counting.

Fix: Shorten the X version. Remember that links count as 23 characters and some Unicode characters count as two.

duplicate-content (403)

X found an identical or near-identical post published recently by the same account.

Fix: Change the post meaningfully before trying again. Repeating the same request will keep failing.

unauthorized (401)

The X access token has expired, was revoked, or no longer belongs to an authorized app session.

Fix: Reconnect the X account and approve posting access again.

Why X (Twitter) uploads fail

  • Photos, video, GIF, poll, or quote-tweet modes are mixed when they are mutually exclusive.
  • Weighted character counting is ignored: URLs count as 23 and some characters count as 2.
  • A GIF exceeds its frame, resolution, or 15 MB limit.

What PublishQ handles

  • Uses weighted X character validation and supports Premium long posts.
  • Keeps polls, media, quote tweets, and reply controls in valid combinations.
  • Prepares each image into the best version X accepts, resizing high-resolution photos that exceed X’s limits and compressing oversized images, so you never have to edit a photo first.
For developers and agents

Publish to X (Twitter) through one API

Send PublishQ the post. We check it, prepare the media, and deliver it to X (Twitter). You can work in the dashboard or connect through the API, CLI, or MCP server.

Frequently asked questions

Common questions about X (Twitter) media sizes and API publishing limits.

What image size works best on X (Twitter)?

1600×900 works well for landscape images. X does not require one fixed static-image resolution, but photos must be JPEG, PNG, or WebP and no larger than 5 MB.

How many images can an X post contain?

An X post can contain up to four photos, or one video, or one GIF. These media modes cannot be mixed.

Can PublishQ post to X from an API or agent?

Use the PublishQ API, CLI, or MCP server for X posts. PublishQ checks text, polls, media combinations, and reply settings before delivery.

You would also like

Docs

Twitter API

API reference for Twitter API.

Read more
Agents

Post to X with the PublishQ MCP server

publishq_create_post covers X polls, quote posts, replies, Communities and reply settings through platformSpecificSettings on the account entry.

Read more
Agents

Post to X from OpenClaw

Wire OpenClaw to X and post from any chat app you already use. No developer account, no OAuth dance, and no upgrade to the account first.

Read more
Free Tool

Post Previewer

See exactly how your posts will look on Twitter, Instagram, LinkedIn, TikTok, and more before you publish. No signup required.

Read more
Free Tool

X (Twitter) carousel generator

Make a four image carousel for X. Write the slides, export at 1080x1350, and post the set as one tweet people tap through instead of a thread.

Read more
Feature

Write Once, Post Everywhere

Preview how your post looks on each platform, customize the text per account if needed, then publish or schedule to all of them at once.

Read more
Feature

Platform-Specific Content

Write different text for each platform in a single post. Shorten for Twitter, go long on LinkedIn, add hashtags for Instagram — without creating separate posts.

Read more
Feature

API & Developer Tools

Schedule posts, manage accounts, and upload media programmatically. Build your own integrations, automate workflows, or connect PublishQ to your existing tools.

Read more
Platform

X (Twitter)

Schedule tweets with text, images, GIFs, video, and polls. Set reply settings and customize text per account. Post without doomscrolling your timeline.

Read more