Searching tweets by place doesn't get every tweet


Hi everyone,

I checked the REST API, then I tried to get tweets for the last week by place_id in my app. For example,I’d like to get all tweets in Pittsburgh (place_id: 946ccd22e1c9cda1), here is the query part:


However, I only got about 5000 tweets and the result also does’t include my own test tweets which the location has been added. Then I compared the results with results on:

Then I found my app only got a small part of all tweets.

Could anyone tell me what happened and what should I do to solve the problem so that I could get all tweets please?


First of all, note that the API only offers 7 days of history. If you’re seeing results on the web that are older than 7 days, they will not be available in the public search API.

Also worth noting that the percentage of Tweets that are geotagged is very small compared to the overall Tweet volume, so generally I’m not surprised that your result set might be small here.

Are there specific examples of Tweets that you expect to find in the API query result, but do not appear?


I understand the API only offers 7 days of history and I also understand Tweets that are geotagged are a small part of the overall Tweet volume. However,
(1) The result doesn’t include my own geotagged tweet (tweet id:697174119092191232)
(2) The online twitter search returned much more tweets than my app.

After I posted this question, I also found that someone said REST API doesn’t return every tweet, how do you think?


Per the Search API documentation:

The Twitter Search API is part of Twitter’s REST API. It allows queries against the indices of recent or popular Tweets and behaves similarly to, but not exactly like the Search feature available in Twitter mobile or web clients, such as search. The Twitter Search API searches against a sampling of recent Tweets published in the past 7 days.

Before getting involved, it’s important to know that the Search API is focused on relevance and not completeness. This means that some Tweets and users may be missing from search results.