Developer tools Stack Exchange, Inc. (Stack Overflow)
Stack Exchange API (Stack Overflow Q&A)
Retrieve public questions, answers and related metadata from Stack Overflow and other Stack Exchange communities.
Source review: 2026-10-30 · Imported: 1 November 2026
A practical starting point
What could you build?
A debugging assistant can find discussions matching an error and show the original answer links.
Before you connect
Retain author and source attribution under the content licence. Respect backoff responses and avoid presenting old answers as current documentation.
Capabilities & requirements
Dated specifications from the licensed source dataset. “Not published” indicates missing information, rather than confirmed absence.
| Capability | Details and source |
|---|---|
| Status | v2.3 current; MCP server beta The docs cover v2.3 as the public version; the hosted MCP server is labelled beta, and API v3 is not yet broadly available. Source (external) · Verified 2026-10-30 on https://api.stackexchange.com/docs |
| API key required | No key for reads Keyless GETs returned HTTP 200 on 2026-10-30; a free Stack Apps key or OAuth token only raises the quota. Source (external) · Verified 2026-10-30 by test request to https://api.stackexchange.com/2.3/info?site=stackoverflow |
| Free tier | Free; free key for more No paid tier for the API; request keys come free with a Stack Apps app registration. Source (external) · Verified 2026-10-30 on https://api.stackexchange.com/docs |
| Rate limit | 300/day per IP keyless; 10,000 with key quota_max 300 in our keyless responses; docs give 10,000 a day by default with a key, over 30 requests/second per IP banned, and backoff to honour. Source (external) · Verified 2026-10-30 on https://api.stackexchange.com/docs/throttle |
| Official MCP server | Official beta, mcp.stackoverflow.com so_search and get_content; Stack Overflow sign-in (OAuth), 100 calls a day per user. Our unauthenticated call returned 401. Source (external) · Verified 2026-10-30 on https://api.stackexchange.com/docs/mcp-server |
| Official SDK | Minimal JavaScript SDK A small JS library for client-side OAuth only; fuller community libraries are listed on Stack Apps. Source (external) · Verified 2026-10-30 on https://api.stackexchange.com/docs/js-lib |
| Data license / terms | CC BY-SA content + API Terms Posts carry content_license (e.g. CC BY-SA 4.0); the API terms require visible attribution to the Stack Exchange Network. Source (external) · Verified 2026-10-30 on https://stackoverflow.com/legal/api-terms-of-use |
| Commercial use allowed | Allowed with attribution The API terms set no commercial ban; attribution and CC BY-SA share-alike apply. The MCP server terms add no training and no long-term caching. Source (external) · Verified 2026-10-30 on https://stackoverflow.com/legal/api-terms-of-use |
| CORS / browser use | Access-Control-Allow-Origin: * GET and an OPTIONS preflight with a third-party Origin returned * on 2026-10-30. Source (external) · Verified 2026-10-30 by test request to https://api.stackexchange.com/2.3/info?site=stackoverflow |
| Freshness / coverage | Live site data, heavily cached Results reflect the live sites; the docs say identical requests within a minute usually return the same cached result. Source (external) · Verified 2026-10-30 on https://api.stackexchange.com/docs/throttle |
Operational reference
Additional facts and qualifications retained from AgentAPIList’s CC BY 4.0 dataset, with provider references.
Price
Free. Reads need no account; registering an app on Stack Apps for a request key is also free.
Provider reference (external)API key / auth
None for reads. Our keyless GETs on 2026-10-30 returned HTTP 200. A request key or OAuth access token only raises the quota; writes and /me routes need an access token.
Provider reference (external)Rate limit
Keyless calls share a per-IP daily quota; our responses showed quota_max 300. The default with a key is 10,000 a day. More than 30 requests a second from one IP gets dropped for 30 seconds to a few minutes, and any method can return a backoff value in seconds that you must honour.
Provider reference (external)Paging caps
Page size up to 100 and up to 100 ids per call. Anonymous access stops at page 25: our request for page 26 returned error 403 “page above 25 requires access token or app key”.
Provider reference (external)License / terms
The API Terms of Use require every app to show visibly that the Stack Exchange Network is the source, and to follow the attribution rules in the Public Network Terms (last updated Nov 13, 2025). Each post carries content_license, for example “CC BY-SA 4.0”.
Provider reference (external)Stack Overflow MCP server
Beta, hosted at mcp.stackoverflow.com with tools so_search and get_content. Sign in with a Stack Overflow account (OAuth); 100 calls a day per user. Its terms forbid model training and long-term storage or caching of the content. Our unauthenticated POST returned HTTP 401.
Provider reference (external)Our check of the trend
969 new Stack Overflow questions were created in September 2026 versus 207,169 in March 2014 (keyless /questions with filter=total, run 2026-10-30).
Provider reference (external)Setup references
HTTP request example
Adapted from the attributed source dataset. Review before running; these examples were not executed by Tech in General.
curl -sS --compressed "https://api.stackexchange.com/2.3/search/advanced?site=stackoverflow&q=streamable%20http&tagged=model-context-protocol&accepted=True&sort=votes&order=desc&pagesize=2"Agent connection example
Adapted from the attributed source dataset. Review before running; these examples were not executed by Tech in General.
// Tool definitions for Claude, OpenAI or any function-calling agent
[
{
"name": "stackoverflow_search",
"description": "Search Stack Overflow questions via the Stack Exchange API. Read-only, no key (300 calls/day per IP). Cite results as Stack Overflow, CC BY-SA.",
"input_schema": {
"type": "object",
"properties": {
"q": { "type": "string", "description": "Free-text query, e.g. an error message" },
"tagged": { "type": "string", "description": "Semicolon-separated tags, e.g. python;fastapi" },
"accepted": { "type": "boolean" },
"pagesize": { "type": "integer", "maximum": 100 }
},
"required": ["q"]
}
},
{
"name": "stackoverflow_answers",
"description": "Fetch answers by id with their body text.",
"input_schema": {
"type": "object",
"properties": { "ids": { "type": "string", "description": "Up to 100 ids separated by semicolons" } },
"required": ["ids"]
}
}
]
// Implementation (decompress gzip; honour any "backoff" field):
// GET https://api.stackexchange.com/2.3/search/advanced?site=stackoverflow&q={q}&tagged={tagged}&accepted={accepted}&pagesize={pagesize}
// GET https://api.stackexchange.com/2.3/answers/{ids}?site=stackoverflow&filter=withbodyA tool schema needs an HTTP implementation; it does not by itself install an MCP server. Keep credentials out of browser code.
Other connections to explore
- Stack Overflow MCP server (beta) (external)
- GitBook docs MCP (external)
- Exa hosted MCP (external)
- GitLab MCP server (external)
Source & reuse
Download the complete licensed source snapshot (JSON), including the original source’s caveats, alternative notes and examples.