Stack Overflow API. Questions, answers and people, as JSON.
Read questions, answers, comments, users, tags and edit history from Stack Overflow and 364 other Stack Exchange sites. Name the site, get one JSON shape.
- 365 Stack Exchange sites
- Typed not_found
- 1 credit per request
- Failed requests aren't charged
Teams running monitoring, research, and enrichment pipelines
Why Social Fetch
Stack Overflow data as JSON. You build the product.
Live Stack Overflow data in one response shape, with platform changes handled for you.
Stack Overflow, plus every other platform
One key and one response envelope for Stack Overflow and 56 more platforms.
Pricing you can reason about
One request, one credit. Know how far your balance will go before you run your next batch.
Live data on every request
Fetch public data when you ask for it.
Nothing to maintain
We handle platform changes and breakages.
Built for production jobs
Run concurrent workloads with explicit statuses and request IDs.
Regular jobs. Better rates.
Running lookups every month? Get lower per-credit rates with a monthly plan. For occasional projects, choose pay as you go.
What Stack Overflow data can you get?
23 endpoints, one API key. Every response comes back as live JSON in the same envelope.
- +1 more questions endpoints
Questions
Answers
- +1 more posts endpoints
Posts
- +5 more users endpoints
Users
Tags
Sites
Browse all 23 Stack Overflow endpoints
Questions
Answers
Posts
Users
Tags
Sites
What teams build with Stack Overflow data
Monitoring, enrichment, research and content workflows on Stack Overflow data, on the same API as every other platform.
How it works
Your first request in three steps.
Use TypeScript or your automation tool of choice.
Sources
+ 51 more platforms
One request
GET/v1/tiktok/profiles/
x-api-key: sk_live_••••••••
Same JSON shape
{
"data": {
"lookupStatus": "found",
"profile": {
"platform": "tiktok",
"handle": "charlidamelio",
"displayName": "charli d’amelio",
"verified": true
},
"metrics": {
"followers": 160263648
}
}
}Step 1
Create your free account
Get an API key with 100 requests included.
Step 2
Choose an endpoint
Pass a username, URL, keyword, or post ID.
Step 3
Get clean JSON
Use the response immediately or send it into your pipeline.
Works with your stack
Code, automate, or connect your AI.
TypeScript
n8n
- Make
- Apify
- MCP
- AI clients
Pricing
Social data, priced simply.
Start with 100 free credits. Monthly plans give you predictable volume and lower per-request rates.
Starter
18,000credits
$1.61 per 1k · $0.00161 per request
- Top up from $1.61 / 1k if you run out
- Up to 25 monitors
Growth
50,000credits
$1.58 per 1k · $0.00158 per request
- Top up from $1.58 / 1k if you run out
- 5 team seats
- Up to 100 monitors
Scale
150,000credits
$1.50 per 1k · $0.00150 per request
- Top up from $1.50 / 1k if you run out
- 25 team seats
- Up to 250 monitors
- Cancel anytime
- 30-day money-back guarantee
- Price locked while you stay
Need 1M+ credits, invoicing, or volume rates? Talk to us
Trust signals
DevHunt
Product Hunt
Uneed
Customers
Teams building on Social Fetch.
“Our TikTok and Instagram scrapers broke constantly. Social Fetch took us off that rotation — we ship product again.”
“Transcripts at volume from one endpoint. No broken scrapers for our small team to maintain.”
“Live profile data on every request. We never flag accounts from a stale cache.”
“Heavy concurrent load, no rate limits to negotiate. The rare API I haven't wrapped in retries.”
Stack Overflow API: common questions
What can I get from the Stack Overflow API?
Questions, answers, comments, users, tags and sites. The 23 routes cover a question lookup, question lists and search, a title search, batches by id, a question's answers, post comments, revision history, a post timeline, citations, user profiles and user activity, the tag list and one tag with its wiki and top answerers.
How do I read a Stack Exchange site other than Stack Overflow?
Pass site on any route: askubuntu, serverfault, math, ru.stackoverflow and so on. A host like math.stackexchange.com or a full site URL is accepted and reduced to the API name. The sites route lists all 365 names, with each site's URL, audience and related sites.
What does lookupStatus mean?
found means the question, user, tag or post exists and the matching object has data. not_found means it does not exist or was deleted, and the object is null. Both come back as HTTP 200, so branch on lookupStatus rather than on the status code.
How do I page through a list?
Read page.hasMore and pass page.nextCursor back as cursor with the same filters. A question, answer, comment or user list sorted by creation pages without a ceiling. Every other sort returns up to 2,500 rows (625 when the page carries text), then stops with limitReached set to true. On a user with more than 2,500 answers or comments, a sort other than creation stops after the first 100 rows (25 with text). Rows with equal scores can repeat or skip on sorts that have ties.
How much does a request cost?
1 credit for a normal lookup or list page. A batch route charges 1 credit per id, up to 100 ids, and an id that is not a question, user or post is still charged. Failed requests that Social Fetch does not bill are free. Check meta.creditsCharged on every response. New accounts start with 100 free credits.
Can I get a question's answers and comments in one call?
Yes. Add include=answers,comments to the question route. answers is filled and answersComplete says whether it holds every answer the answerCount claims. With either part on, a question batch takes at most 10 ids. For a question with many answers, use the answers route and page with creation.
How do I search questions?
Use the search route with q, title, body, tagged, notTagged or user, plus filters such as accepted, closed, answersMin, viewsMin and a date range. mode=excerpt returns questions and answers with highlighted snippets. The title-search route is different: it returns up to 25 questions whose titles are similar to a title you are drafting.
What are the batch routes for?
Question, user and post-comment batches take 1 to 100 ids and return one entry per id, in the order you asked. Each entry has its own lookupStatus, so a mix of existing and missing ids is a normal 200 response. Each id is billed, including a missing one.
Are tag lists exact?
Not for sort=popular or sort=activity. The site picks each page from a ranking that lags the counts it shows, so a tag can be missing from a page and pages can repeat a boundary tag, which we drop. approximate is true for those sorts and the rows keep Stack Exchange's ranking. sort=name is exact.
Can I use these routes from agents or MCP?
Yes. Every Stack Overflow route is a typed MCP tool and is reachable through Ask in plain English. Use the typed routes for production jobs and the MCP or Ask surface for exploration.
The Stack Overflow API in detailHow the Stack Overflow routes work, what they cost, and how they differ from the official API.
Why teams use Social Fetch for Stack Overflow
Social Fetch exposes 23 routes under /v1/stack-overflow. Every one takes site, the API name of a Stack Exchange site: stackoverflow by default, or askubuntu, math, ru.stackoverflow and the rest of the 365 sites that the sites route lists. A site host or URL works too.
Question routes cover one question, a list, a search, a title search, a batch lookup by id, and a question's answers. Post routes cover comments on one post or up to 100 posts, revision history, a timeline of everything that happened to a post, and its citation in BibTeX and AMS form. User routes cover a profile, a batch, a search, and a user's answers, questions, comments, tag activity, badges and reputation history. Tag routes cover the tag list and one tag with its wiki, synonyms, related tags and top answerers.
Lookups return lookupStatus of found or not_found with HTTP 200, so a deleted question is a typed miss rather than an error. Lists page with page.nextCursor; a list sorted by anything other than time returns up to 2,500 rows and then stops with limitReached (625 when it carries text). A user's answer or comment list on an account over 2,500 rows stops after its first 100 rows (25 when it carries text). Batch routes keep the order of the ids you send and charge for each id, found or not.
meta.creditsCharged on every response is the billing source of truth.
How to call the Stack Overflow API
1. Create an API key
Sign up at Social Fetch and copy a key (
sfk_...). New accounts get 100 free credits, enough to try every Stack Overflow route a few times.2. Pick the site and route
Use
sitefor anything other than Stack Overflow itself. For exampleGET /v1/stack-overflow/questions/11?site=stackoverflowfor one question, orGET /v1/stack-overflow/tags/python?site=stackoverflow&include=wikifor a tag. Sendx-api-keyon every request.3. Page and branch
Check
data.lookupStatusbefore you store a row, keep requesting withpage.nextCursorwhilepage.hasMoreis true, and bill frommeta.creditsCharged.
What each Stack Overflow route returns
- One question with its answers and comments when you add
include=answers,comments. - Question lists and search with tags, dates, accepted and closed filters, and excerpt mode.
- Batch lookups for up to 100 question, user or post ids per request.
- Users with reputation, badge counts, accept rate, profile text and activity counts.
- A user's answers, questions, comments, tag activity, badges and reputation history.
- Tags with question counts, synonyms, related tags, wiki text and top answerers.
- Post comments, revision history, a full timeline and citation text.
- All 365 Stack Exchange sites from one
siteslist, with aliases and related sites.
How much does the Stack Overflow API cost?
Each request charges from 1 credit, shown on every endpoint page. Batch routes charge 1 credit per id, including an id that turns out not to exist. Each page of a list is its own request. meta.creditsCharged on every response is the billing source of truth, and new accounts start with 100 free credits.
Social Fetch vs the official Stack Overflow API
The Stack Exchange network is 365 sites, each with its own host, tag set and error behaviour. Social Fetch puts one route group in front of all of them: one JSON envelope, lookupStatus in place of site-specific errors, cursors that say when a list hits a ceiling, and batch routes that answer per id. The site is a parameter, not a separate integration.
Pull your first Stack Overflow data.
Run a live Stack Overflow request in the playground. 100 free credits, no card, JSON back in seconds.
No credit cardSign up in 30 seconds withGoogleGitHub