# Twitter X Profile Viewer (`scraper-engine/twitter-x-profile-viewer`) Actor

Twitter X Profile Viewer extracts public profile information including usernames, display names, bios, profile URLs, follower and following counts, post counts, locations, websites, and profile images. Build structured datasets for audience research, creator discovery, and competitive analysis.

- **URL**: https://apify.com/scraper-engine/twitter-x-profile-viewer.md
- **Developed by:** [Scraper Engine](https://apify.com/scraper-engine) (community)
- **Categories:**
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $4.99 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### Twitter X Profile Scraper — Bio, Followers and Verification Data

Twitter X Profile Viewer pulls public X (Twitter) profile data — bio, follower and following counts, blue-verification status, affiliate badges, and pinned tweet IDs — for any list of usernames or profile URLs, and returns it as clean, structured JSON. No X account, API key, or login is required. Every profile streams straight to the dataset the moment it's parsed. Give it a list of handles and [start a run](#how-to-use-twitter-x-profile-viewer) to see it work.

***

### What is Twitter X Profile Viewer?

Twitter X Profile Viewer is an Apify Actor that fetches a public X (Twitter) profile page for each username or URL you provide, parses the page's own embedded profile data, and returns identity, stats, verification, affiliate-badge, and pinned-tweet fields as one JSON record per profile. It runs against X's logged-out, server-rendered profile pages — no X account, cookie, or API key is needed to use it. It's built for growth and social-media teams, researchers, and developers or AI engineers who need structured public profile data without maintaining their own scraper or an X API integration.

***

### What X (Twitter) profile data is publicly available to scrape?

Anyone who opens a public X profile without logging in can already see the fields below — nothing here requires an account.

| Data Category | Publicly Available (no login) | Restricted (requires login) |
| --- | --- | --- |
| Name, username, bio, location | Yes | — |
| Avatar and banner images | Yes | — |
| Follower / following / tweet counts | Yes | — |
| Blue-verification status and type | Yes | — |
| Affiliate / organization badge | Yes | — |
| Pinned tweet IDs | Yes | — |
| Account creation date | Yes | — |
| Full follower / following lists | No | Requires login |
| Tweet content, timeline, replies, DMs | No | Requires login |

Twitter X Profile Viewer only returns publicly visible data — what any visitor sees. Nothing behind a login wall.

***

### What data can I extract with Twitter X Profile Viewer?

Every run returns identity, engagement, verification, and pinned-content fields for each profile, grouped below exactly as the Actor builds each dataset record.

#### Identity & profile fields

| Field Name | Description |
| --- | --- |
| `user_id` | The account's numeric X/Twitter `rest_id`. |
| `username` | The account's current handle, without the `@`. |
| `name` | The account's display name. |
| `profile_url` | Canonical `https://x.com/<username>` link. |
| `bio` | Profile description text. |
| `location` | Free-text location field on the profile. |
| `profile_image` | Upscaled (400x400) avatar URL. |
| `profile_banner` | Profile header/banner image URL. |
| `created_at` | Account creation date, ISO 8601 UTC. |
| `input` | The exact URL or username string as supplied in the input. |

#### Stats & status fields

| Field Name | Description |
| --- | --- |
| `account_status` | One of `active`, `protected`, `unavailable`, `not_found`, `parse_error`, `invalid_input`. |
| `followers_count` | Follower count at scrape time. |
| `following_count` | Following count at scrape time. |
| `tweets_count` | Total posts count at scrape time. |
| `media_count` | Total photos and videos posted, from the account's Media tab. |
| `is_blue_verified` | Whether the account has an active X Premium / Blue subscription checkmark. |
| `verification_type` | Verification category when set, e.g. Government, Business. |
| `is_protected` | Whether tweets are protected / the account is private. |

#### Affiliate & pinned-content fields

| Field Name | Description |
| --- | --- |
| `affiliate_name` | Name of the affiliated organization badge, if any. |
| `affiliate_url` | Link target of the affiliate badge, if any. |
| `affiliate_badge` | Icon image URL of the affiliate badge, if any. |
| `pinned_tweet_ids` | IDs of tweets currently pinned to the profile. |
| `scraped_at` | UTC timestamp the record was scraped, ISO 8601. |

#### 🤖 Add-on: Need profile data from other platforms too?

Twitter X Profile Viewer is a single-platform scraper — there's no companion X/Twitter Actor in this catalog to cross-sell here. If you're building a cross-platform profile dataset, the same account also publishes a **LinkedIn People Profile Scraper** and an **Instagram Transcript API & Profile Scraper** for the equivalent public-profile fields on those platforms.

***

### How does Twitter X Profile Scraper differ from the official X API?

The official X API requires registering a developer account and app at console.x.com and authenticating every call with a bearer token; Twitter X Profile Viewer needs neither — you paste usernames or URLs and run it. As of the current X API documentation (docs.x.com, checked 2026-09-03), access is billed on a pay-per-usage credit model rather than a fixed free tier, and covers a much broader surface (posts, DMs, Spaces, Lists, trends) that each need their own authorization scope.

| Feature | X API (Official) | Twitter X Profile Viewer |
| --- | --- | --- |
| Account setup | Developer account, app registration, bearer token | None — no account or key |
| Pricing model | Pay-per-usage credits (per current X API docs) | Apify pay-per-event pricing |
| Scope | Broad: posts, DMs, Spaces, Lists, trends, users | Focused: public profile fields only |
| Data source | X's own authorized REST/GraphQL endpoints | Public, logged-out profile pages |
| Output shape | Raw API response shape per endpoint/version | One fixed, flat JSON schema per profile |
| Bulk lookups | One account/session per authorized call | Up to 100,000 usernames/URLs in one run |

Use the official X API when you need authenticated actions (posting, DMs, private timelines) or data outside a public profile page. Use Twitter X Profile Viewer when you only need public profile fields without registering a developer app or managing API credentials.

***

### How to use Twitter X Profile Viewer

Twitter X Profile Viewer is an Apify Actor — there's no separate signup or API key to obtain before your first run.

1. Open the Actor's page on the Apify Store and click **Run**, or start it from your Apify Console.
2. Add your list of profiles in the **`urls`** field — the only required input. Mix bare usernames, `@handles`, and full URLs freely.
3. Optionally set **`proxyConfiguration`** if you want to force a starting proxy tier or region; leave it as-is to let the Actor manage proxy escalation automatically.
4. Start the run.
5. Read results as JSON or CSV from the dataset, or pull them via the Apify API once the run finishes.

#### How to scale to bulk profile extraction

`urls` is an array input (`minItems: 1`, `maxItems: 100000`), so bulk extraction is native — paste as many usernames or URLs as you need into that one field and they all run in a single execution. The Actor normalizes and de-duplicates entries before sending any request, so `elonmusk`, `@elonmusk`, and `https://x.com/elonmusk` in the same list only cost one request.

***

### What can you do with X (Twitter) profile data?

- 🎯 A growth marketer building an outreach list uses `followers_count` and `is_blue_verified` to prioritize established, verified accounts before sending pitches.
- 🕵️ A trust & safety researcher checking impersonation reports uses `verification_type` and `affiliate_badge` to confirm whether an account is genuinely tied to the organization it claims.
- 📈 A social-media analyst benchmarking competitor accounts uses `followers_count`, `following_count`, and `tweets_count` to compare growth and posting cadence over time.
- 🧵 A content team auditing brand accounts uses `pinned_tweet_ids` and `bio` to check what each account is currently featuring without opening every profile manually.
- 🤖 An AI engineer building a lead-enrichment agent feeds `bio`, `name`, and `location` into a RAG pipeline so an LLM can summarize a prospect's public X presence before drafting outreach.

Because output is typed JSON with stable field names, these same fields can be called directly from an agent tool or MCP client — see [Integrations](#integrations) below.

***

### How does Twitter X Profile Viewer handle rate limits and blocking?

The Actor starts every run with no proxy at all. Only if X responds with HTTP 403, 429, or 5xx does it escalate to a datacenter proxy, and only if the datacenter tier is also blocked does it escalate again to a residential proxy — once escalated, the run stays on that tier for every remaining profile rather than flip-flopping. Requests also rotate across `x.com`, `twitter.com`, and `mobile.twitter.com` on a transport failure. Each profile gets up to 3 request attempts by default, with exponential backoff (capped at 20 seconds, plus jitter) between attempts, and up to 5 profiles are processed concurrently.

⚠️ If 12 consecutive requests never reach X at all (a dead proxy or network path, not a block), the run halts early — everything already scraped is preserved in the dataset, but remaining usernames are not attempted.

If a single profile exhausts all retries, it is skipped rather than retried indefinitely; see [FAQ](#frequently-asked-questions) for what that means for row counts.

***

### ⬇️ Input

| Parameter | Required | Type | Description | Example Value |
| --- | --- | --- | --- | --- |
| `urls` | Yes | array of strings | One profile per entry: full URL (`https://x.com/elonmusk`), bare username (`elonmusk`), or `@handle` (`@elonmusk`). `twitter.com` and `mobile.twitter.com` links are accepted too. 1–100,000 entries. | `["elonmusk", "@nasa", "https://x.com/SpaceX"]` |
| `proxyConfiguration` | No | object | Apify Proxy configuration. Defaults to no proxy (`useApifyProxy: false`) — the Actor auto-escalates to datacenter, then residential, only if X actually blocks the run. Set this only to force a starting tier or region. | `{ "useApifyProxy": true }` |

#### Example input

```json
{
  "urls": [
    "elonmusk",
    "nasa",
    "https://x.com/SpaceX",
    "@sundarpichai",
    "https://twitter.com/OpenAI"
  ],
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

***

### ⬆️ Output

Each run produces typed, normalized JSON with the same 23 fields on every record, whether the profile is active, protected, suspended, or missing. Results are available as the full dataset (JSON), a CSV export, and six pre-built dataset views (Overview, Profile details, Statistics, Verification & affiliate, Pinned tweets, Run metadata) for browsing without a wide table.

This Actor uses pay-per-event pricing on the `row_result` event. Any profile that gets far enough to complete a request — active, protected, unavailable, not found, or a parse error — is a billed `row_result`. Rows written for malformed input (`account_status: "invalid_input"`) are saved to the dataset but are **not** charged. To view only billed rows, filter the dataset on `account_status != "invalid_input"`.

#### Example output

```json
{
  "user_id": "44196397",
  "username": "elonmusk",
  "name": "Elon Musk",
  "profile_url": "https://x.com/elonmusk",
  "bio": "Mars, Cars, Chips 'n Dip",
  "location": "Austin, Texas",
  "profile_image": "https://pbs.twimg.com/profile_images/2053244804520427520/m8mdWZCG_400x400.jpg",
  "profile_banner": "https://pbs.twimg.com/profile_banners/44196397/1774145451",
  "is_blue_verified": true,
  "verification_type": null,
  "account_status": "active",
  "followers_count": 241511630,
  "following_count": 1399,
  "tweets_count": 78412,
  "media_count": 9821,
  "created_at": "2009-06-02T20:12:29.000Z",
  "is_protected": false,
  "affiliate_name": "Tesla",
  "affiliate_url": "https://x.com/Tesla",
  "affiliate_badge": "https://pbs.twimg.com/semantic_core_img/1683397672663019521/oYSEyBpN?format=png&name=orig",
  "pinned_tweet_ids": ["1832456789012345678"],
  "scraped_at": "2026-09-03T10:15:22.481Z",
  "input": "elonmusk"
}
```

***

### How does it work?

For each username, the Actor sends a plain HTTPS GET to the profile page using browser TLS impersonation (via `curl_cffi`, impersonating Chrome) — no headless browser is launched. X's current web client server-renders the whole profile object inline in the HTML as embedded React Server Components data, so the Actor parses that block directly rather than calling a private API. A separate, publicly available guest-session call fills in `media_count`, which isn't present on the profile page itself. Field lookups use targeted, anchored patterns with an unscoped fallback for each one, so a single renamed field degrades to `null` instead of breaking the whole record — which keeps the output schema stable across X's UI and template changes. Only what's already visible to a logged-out visitor is ever returned.

***

### Integrations

Twitter X Profile Viewer runs on the Apify platform, so it works with anything that can call an Apify Actor: the REST API, official SDKs, or Apify's own no-code and agent integrations.

#### Calling Twitter X Profile Viewer programmatically

```python
from apify_client import ApifyClient

client = ApifyClient("<APIFY_API_TOKEN>")

run = client.actor("<store-owner>/twitter-x-profile-viewer").call(
    run_input={"urls": ["elonmusk", "nasa", "https://x.com/SpaceX"]}
)

for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item["username"], item["account_status"], item["followers_count"])
```

Works in Go, Ruby, Node.js, cURL — any language that can make an HTTP request with your Apify API token as the bearer credential.

#### MCP integration for AI agents

Twitter X Profile Viewer is reachable through Apify's own MCP server rather than a bundled MCP server of its own. Register the hosted server at `https://mcp.apify.com`, or run it locally with `npx @apify/actors-mcp-server` and an `APIFY_TOKEN` environment variable, then pass this Actor's Store ID via `--actors` so your MCP client (Claude Desktop, or any MCP-compatible agent framework) can call it as a tool.

#### No-code tools (n8n, Make, LangChain)

In n8n, use the Apify node, or an HTTP Request node pointed at the Actor's run endpoint, to trigger a run and pull results straight into your workflow. In Make, add an HTTP module against the same run endpoint with your API token as the bearer header. In LangChain, use `ApifyWrapper` to start the Actor and load its dataset directly as documents for a retrieval pipeline.

***

### Is it legal to scrape X (Twitter) profiles?

Scraping publicly accessible profile data is generally permitted, since Twitter X Profile Viewer only returns what any logged-out visitor can already see on a profile page — nothing behind a login wall. Because profile fields like name, bio, and location can constitute personal data, GDPR and CCPA (and similar regional laws) still govern how you store, process, and reuse it once collected, independent of how it was obtained. Consult legal counsel if your use case involves bulk storage of personal data.

***

### Frequently asked questions

#### What X (Twitter) profile fields does Twitter X Profile Viewer return?

The top fields are `username`, `name`, `bio`, `followers_count`, and `is_blue_verified`, alongside 18 more identity, stats, and affiliate fields — see [What data can I extract](#what-data-can-i-extract-with-twitter-x-profile-viewer) above for the full list.

#### Does Twitter X Profile Viewer require an X account or login?

No. It fetches the same logged-out profile page any anonymous visitor sees; the only authenticated-feeling call it makes internally is a public guest-token request X's own web client uses to bootstrap itself, and it never uses your credentials.

#### How many profiles can I extract in one run?

The `urls` input accepts between 1 and 100,000 entries per run, and duplicates (mixed formats included) are automatically collapsed to a single request before scraping starts.

#### What happens if a profile is private, suspended, or doesn't exist?

Each outcome gets its own `account_status`: `not_found` for a nonexistent handle, `protected` for a private account, `unavailable` for suspended or deactivated accounts, and `parse_error` if X's page structure doesn't match what the Actor expects. All four are still written to the dataset as a full record with the rest of the fields set to `null`. The one exception: if a request to a username fails completely after all retries (a dead connection, not a block), no row is written for it at all — reconcile your output count against your input list if that matters for your use case.

#### Can I scrape multiple X (Twitter) profiles at once?

Yes — `urls` is an array, so a single run accepts any mix of usernames, `@handles`, and full profile URLs up to the 100,000-entry limit.

#### Does Twitter X Profile Viewer work with Claude, ChatGPT, and other AI agent tools?

Yes. It's callable as an HTTP endpoint by any agent framework, and it's reachable through Apify's own MCP server (`https://mcp.apify.com` or `@apify/actors-mcp-server`) for MCP-compatible clients like Claude Desktop.

#### How does Twitter X Profile Viewer compare to other X (Twitter) profile scrapers?

Twitter X Profile Viewer's main structural differences are its 3-tier proxy escalation (direct → datacenter → residential, only when actually blocked) and its dataset schema, which includes verification type, affiliate badge, and pinned tweet IDs alongside the usual identity and count fields in every record.

#### Does Twitter X Profile Viewer return data in a format LLMs can use directly?

Yes. Output is typed, normalized JSON with consistent field names across runs — no HTML parsing or selectors needed. Pass it directly to an LLM, index it into a vector store, or feed it to an agent tool.

#### What happens when X changes its layout or anti-bot system?

The parser is built around anchored field lookups with an unscoped fallback for each one, so an isolated field rename degrades to `null` rather than breaking the run, and the output schema stays the same regardless of X's page structure. No specific update turnaround time is promised.

#### Can I use Twitter X Profile Viewer without managing proxies or browser infrastructure?

Yes. The Actor handles proxy tier selection and escalation (via Apify Proxy) and host fallback internally, and it makes plain HTTPS requests with browser TLS impersonation rather than launching a browser, so there's no headless browser infrastructure to manage either.

#### Which X (Twitter) profile fields work best for AI training data and RAG indexing?

For RAG, index the high-information text fields: `bio`, `name`, and `location`. For structured training features, use the fields that stay consistently typed across every record: `followers_count`, `following_count`, `tweets_count`, `is_blue_verified`, and `account_status`. All fields return as typed primitives (strings, numbers, booleans, or arrays), never as embedded HTML or markup.

***

### Related scrapers

| Scraper Name | What it extracts |
| --- | --- |
| LinkedIn People Profile Scraper | Public LinkedIn profile fields — headline, current role, and public activity. |
| Linkedin Profile Scraper with Email & Company Data (No Cookie) | LinkedIn profiles enriched with email and company details. |
| Instagram Transcript API & Profile Scraper - AI Video to Text | Instagram profile data plus AI-generated video transcripts. |
| TikTok Posts Scraper | Post-level data from TikTok accounts. |
| TikTok Keyword Search Scraper | TikTok posts and accounts matching a search keyword. |

***

### Your feedback

Found a bug, or need a field this Actor doesn't return yet? Let us know at **dev.scraperengine@gmail.com** — bug reports and field requests go straight to the team maintaining this Actor.

# Actor input Schema

## `urls` (type: `array`):

➕ Add one profile per line. Any of these formats work and can be freely mixed: full URL (<code>https://x.com/elonmusk</code>), bare username (<code>elonmusk</code>), or @handle (<code>@elonmusk</code>). twitter.com / mobile.twitter.com links are accepted too. Bulk-friendly — paste as many as you like.

## `proxyConfiguration` (type: `object`):

⚡ <b>Smart 3-tier auto-escalation</b> — this is what most competing profile scrapers skip entirely: 1️⃣ <b>Direct</b> (no proxy) is tried first for every run. 2️⃣ Only if X rejects/blocks that (HTTP 403/429/5xx) does the Actor escalate to a <b>Datacenter</b> proxy. 3️⃣ If the datacenter tier is <i>also</i> blocked, it escalates to a <b>Residential</b> proxy and retries up to 3×. Once escalated, the run sticks with that tier for every remaining profile — no flip-flopping. Leave the default as-is to let the Actor manage this for you; set a country/group below only if you want to override the datacenter tier specifically.

## Actor input object example

```json
{
  "urls": [
    "elonmusk",
    "nasa",
    "https://x.com/SpaceX"
  ],
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `overview` (type: `string`):

All scraped profiles, key columns only.

## `profile` (type: `string`):

Identity, bio, location and images.

## `stats` (type: `string`):

Followers, following, tweets and media counts.

## `verification` (type: `string`):

Blue-verified status, protection and affiliate badges.

## `pinned` (type: `string`):

Pinned tweet IDs per profile.

## `meta` (type: `string`):

Original input, resolved username, status and scrape time.

## `allItems` (type: `string`):

Every field for every scraped profile.

## `csv` (type: `string`):

The full dataset as CSV.

# 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 = {
    "urls": [
        "elonmusk",
        "nasa",
        "https://x.com/SpaceX"
    ],
    "proxyConfiguration": {
        "useApifyProxy": false
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("scraper-engine/twitter-x-profile-viewer").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 = {
    "urls": [
        "elonmusk",
        "nasa",
        "https://x.com/SpaceX",
    ],
    "proxyConfiguration": { "useApifyProxy": False },
}

# Run the Actor and wait for it to finish
run = client.actor("scraper-engine/twitter-x-profile-viewer").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 '{
  "urls": [
    "elonmusk",
    "nasa",
    "https://x.com/SpaceX"
  ],
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}' |
apify call scraper-engine/twitter-x-profile-viewer --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scraper-engine/twitter-x-profile-viewer"
        }
    }
}

```

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/9k6lX16PuTA4CblGh/builds/oU61BWFHyQIR6C5yM/openapi.json
