Skip to content

Twitter API v2: what it is and how to read X data with it

Twitter API v2 explained: what the X API generation covers, how access works, and a simpler read-only route that returns posts and profiles as JSON.

Piyushh · November 7, 2026 · 1 min read

Twitter API v2 is the current generation of the API that Twitter, now X, offers developers. It replaced the older v1.1 endpoints with a cleaner model for posts, users, search and relationships, and most new X code targets it.

What v2 covers

It covers posts and search, user lookup, followers and following, lists and more. Your access tier decides which endpoints you can call. Our guide to whether the X API is free and pricing calculator track that, and does Twitter have an API gives the overview.

Using v2 from code

To use it, you create an app, get keys and call endpoints with a bearer token. For Python, see X API in Python. For rate limits, see X rate limit exceeded.

A read-only route without v2 access

If you only need to read, one key from a hosted API takes the place of choosing an application and a tier:

curl "https://api.chatterapi.com/v1/x/tweets/search?q=open+source+llm" \
  -H "Authorization: Bearer $CHATTERAPI_KEY"

ChatterAPI vs the official X API compares the two routes. The service is independent and not affiliated with X. For JavaScript code, see the Twitter API in JavaScript example.

Related: how to answer the X developer application question.

FAQ

What is Twitter API v2?
It is the current generation of the Twitter (X) API, with endpoints for posts, users, search and more.
Do I need v2 to read posts?
Only if you use the official API. A hosted API gives you its own endpoints and does not need a v2 developer account.
Where are the v2 prices?
See the pricing calculator and the official API comparison, which record the figures with dates.

More on X (Twitter) API

Try it free for 7 days.

1,000 credits to make your first calls. One key for Reddit and X, over REST or MCP.