X (Twitter) Post Scraper avatar

X (Twitter) Post Scraper

Pricing

from $2.00 / 1,000 posts

Go to Apify Store
X (Twitter) Post Scraper

X (Twitter) Post Scraper

Collect X/Twitter profile posts, engagement metrics and author follower counts using your own login session. Supports pagination and excludes replies and retweets. Login cookies are required.

Pricing

from $2.00 / 1,000 posts

Rating

0.0

(0)

Developer

Scraper Creator

Scraper Creator

Maintained by Community

Actor stats

0

Bookmarked

1

Total users

1

Monthly active users

2 days ago

Last modified

Categories

Share

X (Twitter) Post Statistics

Experimental Actor for collecting public profile posts, engagement metrics, and author follower counts using an operator-managed login session. Supply profile URLs and limits; no login credentials are needed in your input.

How to use

  1. Add 1–100 public X/Twitter profile URLs under Profile URLs, such as https://x.com/NASA.
  2. Set Total post limit (maxItems, default 100, range 1–10,000). This limit is shared across all profiles, not applied separately to each one. Start with one profile to avoid leaving later profiles unattempted.
  3. Leave Optional proxy unset unless you need a custom configuration. No proxy is selected automatically; proxy collection has not been validated.
  4. Start the Actor. The operator must already have configured a valid login session; ordinary input contains only target URLs and options, not credentials.
  5. Check the run status and RUN-SUMMARY, then export the dataset or retrieve it through the Apify API. A skipped profile makes the run fail, even if earlier rows were returned.

Replies and retweets are excluded. Pinned posts may be included, and the feed is not guaranteed to be strictly chronological. Search and individual post URLs are not supported.

Input

Run memory defaults are managed in Apify Console under Actor Settings. The source does not declare defaultMemoryMbytes; explicit run, task, or API memory settings can override the cloud default. Memory is a run option, not an input JSON field.

Example

{
"startUrls": ["https://x.com/NASA"],
"maxItems": 100
}

Fields

FieldRequiredDescription
startUrlsYesArray of 1–100 HTTPS X/Twitter profile URLs, as strings or objects containing url.
maxItemsNoTotal output limit across all profiles, from 1 to 10,000; default 100.
proxyConfigurationNoOptional Apify proxy configuration, with one sticky session per profile.

Use x.com, www.x.com, twitter.com, or www.twitter.com without query parameters or fragments. Bare usernames and /status/ links are not accepted.

Output

Each row is one post. Text preserves long-form content and line breaks when supplied by X.

Example

The following is a synthetic example, not live statistics:

{
"id": "1234567890123456789",
"url": "https://x.com/example/status/1234567890123456789",
"inputUrl": "https://x.com/example",
"fullText": "First line\nSecond line #test",
"text": "First line\nSecond line #test",
"createdAt": "2026-10-19T00:00:00.000Z",
"isReply": false,
"isRetweet": false,
"likeCount": 0,
"replyCount": 2,
"retweetCount": 3,
"quoteCount": 1,
"bookmarkCount": 0,
"viewCount": 100,
"author": {
"id": "123",
"userName": "example",
"followers": 42
},
"entities": {
"hashtags": [
{
"text": "test"
}
]
},
"scrapedAt": "2026-10-19T14:38:02.670Z"
}

Fields

FieldDescription
id, url, inputUrlString post ID, canonical post URL, and requested profile.
fullText, text, createdAt, entities.hashtagsPost text, publication time, and hashtags.
isReply, isRetweetBoolean flags; replies and retweets are excluded.
author.id, author.userName, author.followersAuthor identity and current follower count.
likeCount, replyCount, retweetCount, quoteCount, bookmarkCount, viewCountPublic engagement metrics.
scrapedAtCollection time.

Data accuracy

Missing metrics remain null; confirmed zero remains 0. Counts are snapshots and can change after the run.

Viewing and exporting results

Open the run's dataset to view one row per returned post. Export JSON to preserve the nested author object and hashtag arrays, or use a tabular export for spreadsheet analysis. API integrations can retrieve the run's default dataset items.

Open RUN-SUMMARY in the run's default key-value store. Check every requested profile, unattempted targets, and limitReached before treating the output as a complete snapshot. Use successful runs only; rows may remain after a failed run.

Pricing

Check the Actor page for current prices. In pay-per-event runs, each returned result is billable. Proxy usage may add separate charges. Results delivered before a failure or budget stop may already be charged; a failed run does not mean no cost.

Limits and failures

  • The 10,000-post maximum is shared across all profiles. If the limit leaves any profile unattempted, the run fails. A profile reaching the limit is recorded as limitReached, not as full historical coverage.
  • All runs use the operator-configured login session. You do not need to provide passwords or cookies and cannot override the session through input. Expired sessions, account checks, and rate limits stop collection; the operator must renew the session when needed.
  • Inaccessible profiles, malformed data, stalled pagination, and output failures fail the run. Earlier rows may remain; import successful runs only and check requested-profile coverage in RUN-SUMMARY.
  • Budget exhaustion that prevents completion fails the run with stopReason: MAX_TOTAL_CHARGE_REACHED and partial: true.
  • Search, direct-post refresh, standalone follower collection, and other post filters are not supported. Login does not guarantee access to all historical posts.

Refreshing statistics

Start a new run with the same profile URLs and a fresh dataset. The Actor reads the profile feed again up to the shared maxItems limit. Older posts outside that scope are not refreshed, and direct-post refresh is not supported. Follower totals are attached to posts; there is no standalone follower mode.

For API compatibility and operator setup, see DEVELOPMENT.md.