# X (Twitter) Profile Scraper: Bios, Emails & Account Country (`memo23/x-twitter-profile-scraper`) Actor

Look up X (Twitter) profiles in bulk by handle, link or user id: bio, emails and links from the bio, website, location, follower and following counts, join date, verified badge, and the country X says each account is based in. No login.

- **URL**: https://apify.com/memo23/x-twitter-profile-scraper.md
- **Developed by:** [Muhamed Didovic](https://apify.com/memo23) (community)
- **Categories:** Social media, Lead generation
- **Features:** Limited permissions
- **Stats:** 1 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 profiles

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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) Profile Scraper: Bios, Emails & Account Country

Look up **X (Twitter) profiles in bulk** by handle, profile link or numeric user id, without logging in. Every row gives the account's **name, bio, the emails and links written in the bio (short links opened to their real address), website, location, follower, following and post counts, join date, verified badge and type, avatar and banner**. Turn on **"About this account"** to also get the **country X says the account is based in**, how it signed up, its username changes and since when it is verified. **$2.00 per 1,000 profiles.**

```json
{
  "handles": ["nasa", "@apify", "https://x.com/levelsio"],
  "includeAccountDetails": true
}
```

| Input | Rows |
|---|---|
| Handle (`nasa`, `@nasa`) or profile link (`https://x.com/nasa`) | One row per account |
| Numeric user id (`11348282`) or `https://x.com/i/user/11348282` | One row per account, even after a handle change |
| An account that does not exist or is suspended | No row (not charged) |

### Why Use This Scraper?

- **No X account.** Nothing to log in to, no cookies, no API keys; your own account is never at risk.
- **Contacts pulled out for you.** Emails, international phone numbers and every link in the bio land in their own fields, with X's `t.co` short links replaced by the address they open.
- **Where the account is based.** "About this account" adds the country (or region) X shows for the account, the signup source (web or which app store), username changes and the verified-since date.
- **Bulk and fast.** Thousands of handles in one run; about 15 profiles took 7 seconds in testing.
- **Handles, links or ids.** Mix them in one list; ids still work after an account renames itself.

### Use Cases

- **Lead enrichment:** turn a list of X handles into emails, websites and company links.
- **Influencer vetting:** check follower counts, post counts, join date and where an account is really based before you pay it.
- **Fake and bot screening:** spot accounts based far from where they claim, or with many username changes.
- **CRM hygiene:** refresh follower counts, bios and handles for accounts you already track, by id.
- **Research:** build a table of public figures, brands or journalists with their stated location and verified type.

### How It Works

1. Put handles or profile links in **X accounts**, and numeric ids in **User ids** if you have them.
2. Turn on **Add "About this account"** if you want the country, signup source and username history.
3. Each account is looked up once; the bio is read for emails, phones and links, and short links are opened.
4. Download the dataset as JSON, CSV, Excel or HTML, or read it from the API.

### Input Configuration

| Field | Type | Default | What it does |
|---|---|---|---|
| `handles` | array | — | Handles or profile links, one per line. |
| `userIds` | array | — | Numeric X user ids. |
| `includeAccountDetails` | boolean | false | Add "About this account": country, signup source, username changes, verified since. |

Free-plan runs return up to 25 profiles.

#### Example input

Five founders with their country and contacts:

```json
{
  "handles": ["levelsio", "tdinh_me", "arvidkahl", "patio11", "dhh"],
  "includeAccountDetails": true
}
```

### Output Samples

The values below are made up; the fields are what you get.

```json
{
  "type": "profile",
  "input": "https://x.com/example_founder",
  "handle": "example_founder",
  "url": "https://x.com/example_founder",
  "userId": "1234567890",
  "name": "Alex Example",
  "bio": "Founder @ExampleCo. hello@example.com | https://t.co/abc123",
  "email": "hello@example.com",
  "emails": ["hello@example.com"],
  "phones": [],
  "links": ["https://example.com", "https://exampleco.io/"],
  "website": "https://example.com",
  "location": "Berlin",
  "followers": 48210,
  "following": 612,
  "tweets": 13120,
  "mediaCount": 1420,
  "createdAt": "2014-06-18T15:39:26.000Z",
  "verified": true,
  "verificationType": null,
  "isProtected": false,
  "affiliation": null,
  "avatar": "https://pbs.twimg.com/profile_images/example_normal.jpg",
  "banner": "https://pbs.twimg.com/profile_banners/1234567890/1700000000",
  "pinnedTweetIds": ["1850000000000000000"],
  "detailsIncluded": true,
  "accountBasedIn": "Germany",
  "accountLocationAccurate": true,
  "connectedVia": "Germany App Store",
  "usernameChanges": 1,
  "lastUsernameChangeAt": "2019-03-02T10:15:00.000Z",
  "verifiedSince": "2023-05-11T08:00:00.000Z",
  "affiliatedWith": null,
  "accountDetailsIncluded": true,
  "scrapedAt": "2026-11-13T09:00:00.000Z"
}
```

### Key Output Fields

| Field | Meaning |
|---|---|
| `handle`, `name`, `url`, `userId` | The account. `userId` stays the same if the handle changes. |
| `email`, `emails`, `phones`, `links` | Contacts written in the bio. `links` starts with the website, and short links are opened to their real address. |
| `followers`, `following`, `tweets`, `mediaCount` | The account's counts. |
| `verified`, `verificationType`, `affiliation` | Checkmark, its type (Business, Government) and the organization badge. |
| `accountBasedIn`, `accountLocationAccurate` | The country or region X shows under "About this account", and whether X marks it accurate. |
| `connectedVia`, `usernameChanges`, `lastUsernameChangeAt`, `verifiedSince` | How the account signed up, its username history, and when it was verified. |
| `detailsIncluded` | `false` on the rare row read while the full profile was unavailable: `website`, `banner`, `mediaCount`, `verificationType` and `isProtected` are then empty. |
| `accountDetailsIncluded` | `true` when "About this account" was read for this row. |
| `input` | What you typed for this account, so rows match your list. |

### FAQ

**Do I need an X account or API keys?**
No. Give handles and run it.

**Does every account show a country?**
Most personal and company accounts do. Some, such as several government accounts, hide it; `accountBasedIn` is then empty and the row is still saved.

**What happens with accounts that do not exist?**
They are skipped and not charged. The run's last log line counts them.

**Are the emails verified?**
No. They are what the account wrote in its bio.

**How fresh is the data?**
Every run reads the profiles at that moment.

### Pricing

- **$2.00 per 1,000 profiles** saved ($0.002 a profile).
- **"About this account": $2.00 per 1,000 more**, only on profiles where it comes back.
- No start fee beyond Apify's own $0.00005 a run.
- Missing and suspended accounts, and skipped lines, are free.
- Free-plan accounts get up to 25 profiles a run to try it.

### Support

Found an account that does not come through, or need a field we do not return? Open an issue on the Issues tab with the handle. We read every issue.

### Explore More Scrapers

- [X (Twitter) Followers & Following Scraper](https://apify.com/memo23/x-twitter-followers-scraper): followers of any account, with bios and emails.
- [X (Twitter) Replies Scraper](https://apify.com/memo23/x-twitter-replies-scraper): replies under any post, with likes and authors.
- [X (Twitter) Search Scraper](https://apify.com/memo23/x-twitter-search-scraper): tweets by keyword, profiles, trends, communities and lists.
- [Twitter (X) Profile & Tweets Scraper](https://apify.com/memo23/twitter-x-scraper): the posts on any profile's timeline.

### 🤖 For AI Agents & LLM Apps

Call it with `{"handles": ["<handle>", "<handle>"]}` and read the default dataset. Each row is one account with stable keys; `userId` is the join key across runs and `input` echoes what you sent. Add `"includeAccountDetails": true` when the country matters.

### ⚠️ Disclaimer

This actor collects only information X shows publicly on profiles and on the "About this account" page. It does not log in or read protected posts. Profile data is personal data: you are responsible for having a lawful basis to process it under the laws that apply to you (for example the GDPR or CCPA) and for following X's Terms of Service. Do not use the output for spam or unsolicited bulk messaging. This actor is not affiliated with or endorsed by X Corp.

### SEO Keywords

twitter profile scraper, x profile scraper, twitter user scraper, twitter profile lookup, bulk twitter profiles, twitter bio scraper, twitter email finder, x account country, twitter account location, about this account twitter, twitter user id lookup, twitter followers count checker, x profile data export

# Actor input Schema

## `handles` (type: `array`):

Accounts to look up: a handle (nasa, @nasa) or a profile link (https://x.com/nasa, https://x.com/i/user/11348282), one per line.

## `userIds` (type: `array`):

Numeric X user ids, for example 11348282. Use these when you have ids from another export; they still work after an account changes its handle.

## `includeAccountDetails` (type: `boolean`):

Also read what X shows under "About this account": the country the account is based in, how it signed up (web or which app store), how many times it changed its username and when, and since when it is verified. Charged as one extra event per profile where it comes back.

## Actor input object example

```json
{
  "handles": [
    "nasa",
    "apify"
  ],
  "includeAccountDetails": false
}
```

# Actor output Schema

## `results` (type: `string`):

X profiles with bio, contacts, counts and, when asked for, the country each account is based in.

# 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 = {
    "handles": [
        "nasa",
        "apify"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("memo23/x-twitter-profile-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 = { "handles": [
        "nasa",
        "apify",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("memo23/x-twitter-profile-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 '{
  "handles": [
    "nasa",
    "apify"
  ]
}' |
apify call memo23/x-twitter-profile-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,memo23/x-twitter-profile-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/jKLhjxijjDKwy3TEF/builds/2tg3sRWT8Y9EW4tkE/openapi.json
