Twitter Video Downloader avatar

Twitter Video Downloader

Pricing

from $5.00 / 1,000 results

Go to Apify Store
Twitter Video Downloader

Twitter Video Downloader

Download videos from Twitter/X posts. Supports direct post URLs and username-based scraping.

Pricing

from $5.00 / 1,000 results

Rating

5.0

(25)

Developer

Crawler Bros

Crawler Bros

Maintained by Community

Actor stats

23

Bookmarked

32

Total users

8

Monthly active users

13 days ago

Last modified

Share

Twitter / X Media Downloader

Download videos, photos, and GIFs from any public Twitter / X post — no login required for direct post URLs. Paste a link, hit run, and get the file plus a direct download URL that works anywhere.

You can also pass usernames to automatically pull media from a user's recent posts (cookie-authenticated, with a built-in cookie pool fallback).

What you get

Each downloaded file produces one dataset record:

FieldDescription
tweet_urlOriginal tweet URL
tweet_idTweet ID
scraped_fromUsername whose profile this post was found on (null for direct URLs)
uploaderTwitter handle of whoever posted the media
is_retweettrue if the post is a retweet
is_quote_tweettrue if the post quotes another tweet
media_origin"self" = media from the tweet itself, "quoted" = media from a quoted tweet
media_type"video", "photo", or "gif"
media_urlOriginal Twitter CDN URL of the media
thumbnail_urlPreview thumbnail URL (when present)
filenameSaved file name
filesize_bytesFile size in bytes
storage_keyKey used to store the file in the Apify Key-Value Store
download_urlSigned direct download URL — works in any browser or curl
download_status"finished" or "failed"
errorError message (only when download_status="failed")
downloaded_atISO 8601 UTC timestamp
media_statsResolution, duration, codec, bitrate, aspect ratio (where applicable)

Empty fields are dropped from each record so the dataset stays clean.

media_stats fields

StatApplies toExample
width / heightAll media1920 / 1080
fpsVideos / GIFs30.0
durationVideos / GIFs45.23 (seconds)
video_codecVideos / GIFs"h264"
extAll media"mp4", "png", "jpg"
filesize_bytesAll media28640256
total_bitrate_kbpsVideos5064.12
aspect_ratioAll media1.78

Input

ParameterTypeDefaultDescription
postUrlsArray[]Tweet/post URLs to download media from.
usernamesArray[]Twitter handles to pull recent media from (without @).
maxPostsPerUserInteger10Number of recent posts to check per username (1-100).
browserCookiesStringOptional Twitter/X session cookies (JSON). Improves reliability for username scraping; not needed for direct post URLs.

You can mix postUrls and usernames in the same run.

Example input — single post

{
"postUrls": ["https://x.com/NASA/status/1234567890"]
}

Example input — username scrape

{
"usernames": ["NASA", "SpaceX"],
"maxPostsPerUser": 25
}

Example input — mixed

{
"postUrls": ["https://x.com/elonmusk/status/9876543210"],
"usernames": ["openai"],
"maxPostsPerUser": 10
}

Example output

Video

{
"tweet_url": "https://x.com/NASA/status/1234567890",
"tweet_id": "1234567890",
"scraped_from": null,
"uploader": "NASA",
"is_retweet": false,
"is_quote_tweet": false,
"media_origin": "self",
"media_type": "video",
"media_url": "https://video.twimg.com/ext_tw_video/.../pu/vid/1280x720/video.mp4",
"thumbnail_url": "https://pbs.twimg.com/ext_tw_video_thumb/.../img/thumb.jpg",
"filename": "1234567890_video_1.mp4",
"filesize_bytes": 28640256,
"storage_key": "1234567890_video_1.mp4",
"download_url": "https://api.apify.com/v2/key-value-stores/{STORE_ID}/records/1234567890_video_1.mp4?signature=fDeGdoTU7pRBdtunucWD",
"download_status": "finished",
"downloaded_at": "2026-05-05T13:42:18Z",
"media_stats": {
"width": 1920,
"height": 1080,
"fps": 30.0,
"duration": 45.23,
"video_codec": "h264",
"ext": "mp4",
"filesize_bytes": 28640256,
"total_bitrate_kbps": 5064.12,
"aspect_ratio": 1.78
}
}

Photo

{
"tweet_url": "https://x.com/NASA/status/9876543210",
"tweet_id": "9876543210",
"uploader": "NASA",
"media_type": "photo",
"media_url": "https://pbs.twimg.com/media/AbCdEf123.png?name=orig",
"filename": "9876543210_photo_1.png",
"filesize_bytes": 29387,
"download_url": "https://api.apify.com/v2/key-value-stores/{STORE_ID}/records/9876543210_photo_1.png?signature=...",
"download_status": "finished",
"downloaded_at": "2026-05-05T13:42:18Z",
"media_stats": {
"width": 1200,
"height": 675,
"ext": "png",
"filesize_bytes": 29387,
"aspect_ratio": 1.78
}
}

Use cases

  • Content archival — Backup tweets from accounts you care about (your own, journalists, NASA, etc.).
  • Repurposing — Pull video/image assets for blog posts, presentations, or social repurposing.
  • Compliance — Preserve evidence of public posts for legal or regulatory archives.
  • Media research — Build labelled datasets of viral video/image content.
  • Account audit — Pull every video a user has posted to review or migrate.

FAQ

Do I need a Twitter account? No. For direct post URLs, the actor downloads from public endpoints without authentication. Username scraping uses an internal cookie pool that works out of the box; supplying your own cookies via browserCookies improves reliability for heavy username workloads.

What media types are supported? Videos, photos, and GIFs. The actor detects the type automatically and downloads everything in the tweet — if a post has 3 photos and 1 video, you get all 4 files.

What about CMAF / fMP4 streaming videos? Twitter delivers some videos as fragmented MP4 streams (HLS/m3u8). The actor automatically detects this, picks the highest-quality variant, downloads all segments, and produces a single playable MP4.

What does media_origin mean?

  • "self" — the media belongs to the tweet you linked.
  • "quoted" — the tweet you linked quotes another tweet, and this media comes from that quoted tweet. uploader shows the original author.

What does scraped_from mean? For username scraping, it tells you which profile the post was found on — useful when the post is a retweet (uploader is the original author, scraped_from is the user whose timeline produced the URL). For direct postUrls, it's null.

Does it download the best quality available? Yes. Videos are downloaded at the highest variant Twitter exposes; photos at original (?name=orig) resolution.

Are there any file-size limits? No. Files are streamed to disk and uploaded to Apify Key-Value Store, so multi-gigabyte videos work without running out of memory.

Why is download_url signed? Apify Key-Value Store records require a signed URL for public access — the signature is appended automatically. You can paste the URL into any browser or curl and it will download the file directly.

Can I download from private / protected accounts? Only by supplying cookies from an account that follows the protected profile. The actor cannot bypass Twitter's privacy controls.

What happens if a download fails? Failed downloads still appear in the dataset with download_status: "failed" and a clear error (e.g. tweet deleted, media URL expired, rate limit). Successful downloads continue regardless.

How long are the download links valid? Apify Key-Value Store retention depends on your plan — typically 7 days on the free tier, longer on paid plans. Re-run the actor or copy the file to your own storage for permanent archival.

Can I use this on a schedule? Yes. Schedule the actor on the Apify platform to automatically pull new media from specific users at regular intervals (hourly, daily, etc.).

Limitations

  • Private / protected accounts require cookies from a follower.
  • Tweets that were deleted before the run started cannot be retrieved.
  • Twitter rate-limits aggressive crawling; very large username scrapes (50+ users × 100 posts each) may slow down or pause for cool-off.
  • Download URLs are valid as long as your Apify storage retention allows.