# X (Twitter) Tweet Search Scraper 🔎 (keyword, no login) (`tagadanar/x-tweet-search-scraper`) Actor

Search X (Twitter) posts by keyword, phrase, #hashtag, from:account or date window, through the posts Google has indexed, then get each post in full: text, author, date, likes, replies, media, links. No login, no API key. $0.015 per Google page + $0.20 per 1,000 posts.

- **URL**: https://apify.com/tagadanar/x-tweet-search-scraper.md
- **Developed by:** [Tagada Data](https://apify.com/tagadanar) (community)
- **Categories:** Social media, News, AI
- **Features:** Limited permissions
- **Stats:** 5 total users, 4 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $10.50 / 1,000 google results pages

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## X (Twitter) Tweet Search Scraper 🔎 (keyword, no login)

Type a keyword, an "exact phrase", a #hashtag or `from:account`, optionally a date window, and get back X (Twitter) posts that match: one row per post with its full text, author, posted date, likes, replies, photos and videos, links, hashtags, mentions, the quoted post and the post it replies to, plus the Google result that found it. No X account, no cookies, no API key.

**$0.015 per Google results page read plus $0.20 per 1,000 posts, on Free ($0.0105 per page and $0.14 per 1,000 posts on Gold), plus $0.001 per run. Platform usage is included.** A Google page holds about 10 results, so a page that yields 10 posts costs $0.017.

**Read this first: this searches the X posts Google has indexed, not X's live search.** X's own search needs a logged-in account, and this actor never logs in. Google indexes the posts people saw most (popular accounts, posts with engagement), so very recent posts, small accounts and replies are often missing, and the order is Google's, not "latest". If you need every post from the last ten minutes, this is the wrong tool. If you need the visible posts on a topic, or one account's indexed posts on a topic, with full details, it is a good fit.

### What you get

One flat row per post. Fields X does not publish for a post are null.

| Field | What it is |
| --- | --- |
| `query` | Your query, as typed |
| `googleQuery` | The Google query sent for it (see "How queries are translated") |
| `googlePage`, `googleRank` | The Google results page, and the result's position on it (null when the post was found elsewhere on the page) |
| `googleTitle`, `googleSnippet`, `googleDate` | The Google result's title, excerpt and date label |
| `foundVia` | `result` (a Google result) or `page` (a post link found elsewhere on the results page) |
| `tweetId`, `url` | The post id and its x.com link |
| `text` | Full text, t.co links expanded |
| `isLongPost` | true when the post is a long post (only its first ~280 characters are public in this view) |
| `lang`, `createdAt` | X's language code and the posted time (ISO 8601) |
| `authorHandle`, `authorName`, `authorId`, `authorUrl`, `authorAvatarUrl` | The account that posted |
| `authorIsVerified`, `authorIsBlueVerified`, `authorVerifiedType`, `authorAffiliation` | Checkmarks and affiliation badge |
| `likeCount`, `replyCount` | Likes and replies |
| `media`, `mediaTypes`, `mediaUrls`, `videoUrl` | Photos (full size), videos and GIFs with every MP4 variant |
| `links`, `hashtags`, `cashtags`, `mentions` | Entities in the text |
| `isReply`, `inReplyToTweetId`, `inReplyToHandle`, `inReplyToUserId`, `replyTo`, `conversationId` | Reply context (the parent post in compact form) |
| `isQuote`, `quotedTweetId`, `quotedTweet` | The quoted post, in compact form |
| `card` | Link preview, poll or broadcast card |
| `possiblySensitive`, `isEdited`, `editHistoryIds` | Flags from X |
| `status`, `statusDetail` | `ok` for a delivered post, else why there is no post (see below) |
| `scrapedAt` | When the row was read |

Not in the rows: repost, quote and view counts, and author follower counts. X's public post view does not publish them, so there are no such columns rather than always-empty ones.

### Who uses it

- Brand and PR teams: what people post about a product, a launch or an incident, with the full post and its engagement.
- Researchers and journalists: the visible posts on a topic within a date window, or one account's posts on a subject (`from:account topic`).
- AI and data teams: clean post text with author and engagement for classification, sentiment or retrieval.

### Examples

The canary run (one query, one Google page):

```json
{"queries":["web scraping"],"maxPagesPerQuery":1,"maxTweetsPerQuery":10}
```

One account's posts on a subject, and an exact phrase within a date window:

```json
{"queries":["from:NASA moon","\"supply chain\" since:2026-10-01"],"maxPagesPerQuery":2}
```

Several topics at once, French-language results only, last quarter:

```json
{"queries":["intelligence artificielle","\"voiture électrique\""],"since":"2026-08-01","until":"2026-11-01","language":"fr","maxTweetsPerQuery":50}
```

### How queries are translated

Each query becomes one Google query pinned to X post links:

| You type | Sent to Google |
| --- | --- |
| `bitcoin etf` | `site:x.com/*/status bitcoin etf` |
| `from:NASA moon` | `site:x.com/NASA/status moon` |
| `#nvidia` | `site:x.com/*/status "#nvidia"` (Google drops a bare #tag) |
| `openai since:2026-08-01 until:2026-09-01` | `site:x.com/*/status openai after:2026-08-01 before:2026-09-01` |

Other Google operators (`-word`, `OR`, `"exact phrase"`) pass through unchanged. A query that carries its own `site:` is sent as typed. Google filters dates on the date it holds for the page, which is usually, but not always, the posted date. So the actor also checks each post's own date from X (`createdAt`, UTC): a post outside your `since` / `until` window is skipped, not charged, and counted in the run status. `until` is not included (`until:2026-09-01` means up to 31 August). With `from:account`, a post by another account (for example a post id Google showed elsewhere on the results page) is skipped the same way.

### Results, zeros and errors

Every post found gets a row, except posts outside your date window or by another account than your `from:` one, which are skipped, not charged, and counted in the status. Only rows with `status` = `ok` are charged; the others are free and say why:

| status | Meaning |
| --- | --- |
| `ok` | Post read from X and delivered (charged) |
| `not_found` | X has no public post with this id any more (deleted, protected or suspended account) |
| `unavailable` | X withholds the post and says why (in `statusDetail`) |
| `no_tweet_id` | Google showed the result but hid its link, so the post id is unknown: Google title, snippet and author handle only |
| `error` | X did not answer for this post; re-run it |
| `not_reached` | The run's timeout or your maximum charge was reached first |

- A query Google answers with no results ends "no results" and is not charged a page.
- A query stops paging after the first Google page that brings no new post, so you pay for at most one such page per query.
- A query Google refused, or the run clock stopped, is named in the status message and is never reported as "no results".
- A post found under two queries or two pages is delivered once.
- Invalid input ends the run right away with an "Input error: ..." message and only the $0.001 start charge.

### Pricing

- $0.001 per run (start).
- $0.015 per Google results page read (about 10 results) on Free, with lower prices on higher Apify plans ($0.0105 on Gold). The page price is the same whatever share of its results turn out to be readable posts.
- $0.20 per 1,000 posts delivered with status `ok` on Free ($0.14 per 1,000 on Gold). Rows with any other status (`not_found`, `unavailable`, `no_tweet_id`, `error`, `not_reached`) add nothing.
- Platform usage is included.

`maxPagesPerQuery` bounds the page charges: at most queries x pages. Set a maximum charge per run in Apify if you want a hard ceiling; the actor stops at it and says so in the status.

### FAQ

**Why not X's own search?** X's search works only for logged-in accounts. This actor never logs in and uses no account, so it reads Google's index of public X posts and then reads each post from X's public post view, the one X serves when a post is embedded on a website.

**Why are some posts I can see on X missing?** Google has not indexed them (yet). Very recent posts, replies and small accounts are indexed less often. Widen the date window or try other wording.

**Why do some rows have `no_tweet_id`?** On some results pages Google hides every result link behind a redirect, and only a few of those redirects can be followed per run. When the actor cannot learn the post id, it still gives you Google's title, snippet and author handle, with no post charge; the Google page itself is still charged. How often this happens varies from page to page and from query to query, so the number of posts per page varies too: plan on fewer than 10 posts per page on average.

**Can I get an account's latest posts?** Use `from:account` with a topic for its indexed posts. For posts by URL or id, use our X Tweet Scraper.

### Data use

Data comes from Google's public results pages and from X's public embed view, the same data shown when a post is embedded on a website. Only public posts are returned. Rows include public account names and handles; if you process data about people in the EU or UK, you are responsible for having a lawful basis under GDPR. Respect X's terms and the rights of the people who posted.

# Changelog

This Actor's version history is a separate document: https://apify.com/tagadanar/x-tweet-search-scraper/changelog.md

# Actor input Schema

## `queries` (type: `array`):

One search per line: words, an "exact phrase", a #hashtag, from:handle to keep one account's posts, since:YYYY-MM-DD / until:YYYY-MM-DD for a date window, -word to exclude. Each query searches the X posts Google has indexed. Up to 50 queries per run.

## `maxTweetsPerQuery` (type: `integer`):

Stop a query after this many posts. Default 20, max 200.

## `maxPagesPerQuery` (type: `integer`):

Google results pages read per query (about 10 results each). Each page read is one search-page charge. A query also stops early when a page brings no new post. Default 3, max 10.

## `since` (type: `string`):

Optional, YYYY-MM-DD (UTC). Sent to Google as after:, then checked on each post's own date from X: a post Google returns from before this day is skipped and not charged. A since: inside a query wins.

## `until` (type: `string`):

Optional, YYYY-MM-DD (UTC), this day not included. Sent to Google as before:, then checked on each post's own date from X: a post Google returns from this day or later is skipped and not charged. An until: inside a query wins.

## `language` (type: `string`):

Optional. Google's language filter (lr): keeps results Google detects in this language. Each row also carries X's own language code (lang).

## Actor input object example

```json
{
  "queries": [
    "web scraping"
  ],
  "maxTweetsPerQuery": 20,
  "maxPagesPerQuery": 3
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "queries": [
        "web scraping"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("tagadanar/x-tweet-search-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "queries": ["web scraping"] }

# Run the Actor and wait for it to finish
run = client.actor("tagadanar/x-tweet-search-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "queries": [
    "web scraping"
  ]
}' |
apify call tagadanar/x-tweet-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,tagadanar/x-tweet-search-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/gbjPLglaD2ua7Z4m5/builds/EpbxdDFum5S0wBhWc/openapi.json
