GETusers

Get Twitter Profile by Username

Look up any Twitter user by their @username. Get the complete profile including bio, stats, verification status, and profile images in one call.

Average response time: 70ms

Code Examples

const response = await fetch(
  'https://scrapebadger.com/v1/twitter/users/elonmusk/by_username',
  { headers: { 'x-api-key': 'YOUR_API_KEY' } }
);
const user = await response.json();
console.log(user.data.name, user.data.bio);
Response
{
  "data": {
    "id": "44196397",
    "username": "elonmusk",
    "name": "Elon Musk",
    "bio": "Mars & Cars, Chips & Dips",
    "followers_count": 170000000,
    "following_count": 500,
    "tweet_count": 45000,
    "verified": true,
    "created_at": "2009-06-02T20:12:29Z"
  }
}

API Reference

GET/v1/twitter/users/{username}/by_username
ParameterTypeRequiredDescription
usernamestringRequiredThe Twitter username (without @)

Use Cases

Influencer Research

Identify and vet influencers by analyzing follower quality, engagement rates, audience demographics, and content authenticity.

Competitor Analysis

Track competitor accounts, engagement rates, and content strategies to benchmark performance and identify opportunities.

Audience Analysis

Profile your audience by analyzing follower demographics, interests, activity patterns, and engagement behavior.

Recruitment & Talent

Discover and research potential hires by analyzing their public Twitter activity, expertise signals, and professional network.

Bot Detection

Identify automated accounts and inauthentic behavior by analyzing posting patterns, account metadata, and network structures.

Lead Generation

Find potential customers by monitoring purchase-intent keywords, industry discussions, and competitor dissatisfaction signals.

Frequently Asked Questions

No. Twitter usernames are case-insensitive, so "ElonMusk" and "elonmusk" return the same profile.

The API returns a 404 error for usernames that don't exist or have been deactivated.

You can get basic profile info for private accounts (name, bio, follower count) but not their tweets or detailed data.

This endpoint uses the @username (e.g., "elonmusk") while Get User by ID uses the numeric ID (e.g., "44196397"). Both return the same data.