PrerequisitesBefore you begin, you’ll need:
- A developer account
- Your App’s Bearer Token (found in the Developer Console under “Keys and tokens”)
Step 1: Build a query
Full-archive search supports all query operators. Build queries the same way as recent search:Step 2: Set a time range
By default, results return Posts from the last 30 days. Usestart_time and end_time to search specific periods:
| Parameter | Format | Example |
|---|---|---|
start_time | ISO 8601 | 2020-01-01T00:00:00Z |
end_time | ISO 8601 | 2020-12-31T23:59:59Z |
Step 3: Make a request
cURL
Step 4: Review the response
Posts created before the edit feature was introduced (September 2022) won’t include
edit_history_tweet_ids.Step 5: Add fields and expansions
Request additional data with query parameters:cURL
Step 6: Paginate through results
The SDKs handle pagination automatically. For cURL, use thenext_token from the response:
Pagination guide
Learn more about navigating large result sets
Key differences from recent search
| Feature | Recent Search | Full-Archive Search |
|---|---|---|
| Time range | Last 7 days | March 2006 to now |
| Access required | All developers | Pay-per-use, Enterprise |
| Max results per request | 100 | 500 |
| Query length | 512 chars | 1,024 chars |
| Rate limit | 450 / 15 min | 300 / 15 min, 1 / sec |
| Authentication | App-Only, User Context | App-Only only |
Common parameters
| Parameter | Description | Default |
|---|---|---|
query | Search query (required) | — |
max_results | Posts per page (10-500) | 10 |
start_time | Oldest Post timestamp | 30 days ago |
end_time | Newest Post timestamp | Now |
next_token | Pagination token | — |
tweet.fields | Additional Post fields | id, text |
expansions | Related objects to include | — |