Wikipedia API: Get page views
Returns human-reader view counts for a Wikipedia article by day or month, with totals, daily averages and the peak period.
Unofficial. Not affiliated with or endorsed by Wikipedia.
Inputs
Values from the run on Oct 23, 2026, shown under Output.
- Topic, required
topic The Wikipedia article name, such as Taylor Swift.
Taylor Swift
- End Date optional
end_date Last date to count, inclusive, such as 2026-08-31. Defaults to yesterday.
Not set
Date.
- Group by optional
group_by Group views by day or month, such as month. Defaults to day.
day (default)
One of
day,month.- Language optional
language Wikipedia language name or code, such as French or fr. Defaults to English.
English (default)
- Start Date optional
start_date First date to count, inclusive, such as 2026-08-01. Defaults to 29 days before the end date.
Not set
Date.
Input as JSON
{ "topic": "Taylor Swift"}Output
{ "peak": { "date": "2026-09-28", "views": 49080 }, "views": [ { "date": "2026-09-23", "views": 27097 }, { "date": "2026-09-24", "views": 19750 }, { "date": "2026-09-25", "views": 37056 } ], "end_date": "2026-10-22", "start_date": "2026-09-23", "total_views": 517194, "article_link": "https://en.wikipedia.org/wiki/Taylor_Swift" , "article_title": "Taylor Swift", "average_views_per_day": 17239.8}Code
curl https://api.fous.com/v1/runs \ -H "Authorization: Bearer $FOUS_API_KEY" \ -H "Content-Type: application/json" \ -d '{"method":"wikipedia.org/get_page_views","input":{"topic":"Taylor Swift"}}' # Save as fous.py, then run: python3 fous.pyimport json, os, timefrom urllib.error import HTTPErrorfrom urllib.request import Request, urlopenAPI = "https://api.fous.com/v1/runs" KEY = os.environ["FOUS_API_KEY"]HEADERS = { "Authorization": f"Bearer {KEY}", "Content-Type": "application/json" ,}def call(url, body=None): data = json.dumps(body).encode() if body else None request = Request(url, data, HEADERS) try: with urlopen(request, timeout=120) as r: return r.status, json.load(r) except HTTPError as error: message = json.load(error)["error"]["message"] raise RuntimeError(message) from errorstatus, run = call(API, { "method": "wikipedia.org/get_page_views" , "input": { "topic": "Taylor Swift" }})# 202: still going after 30 s. Ask again until it ends.while status == 202: time.sleep(2) status, run = call(f"{API}/{run['id']}")print(json.dumps(run["data"], indent=2))// Save as fous.mjs, then run: node fous.mjsconst api = "https://api.fous.com/v1/runs" ;const headers = { Authorization: `Bearer ${process.env.FOUS_API_KEY}`, "Content-Type": "application/json" ,};let response = await fetch(api, { method: "POST", headers, body: JSON.stringify({ "method": "wikipedia.org/get_page_views" , "input": { "topic": "Taylor Swift" } }), signal: AbortSignal.timeout(120_000),});let run = await response.json();// 202: still going after 30 s. Ask again until it ends.while (response.status === 202) { await new Promise((done) => setTimeout(done, 2_000)); response = await fetch(`${api}/${run.id}`, { headers }); run = await response.json();}if (!response.ok) throw new Error(run.error.message);console.log(run.data);# Connect your agent to Fous once, over MCP (Streamable HTTP):# https://api.fous.com/mcp# Set FOUS_API_KEY first: create a key at https://app.fous.com/keys.# Claude Codeclaude mcp add \ --scope user \ --transport http fous https://api.fous.com/mcp \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Codexcodex mcp add fous \ --url https://api.fous.com/mcp \ --bearer-token-env-var FOUS_API_KEY# Cursor, VS Code, Windsurf, Cline and morenpx -y add-mcp https://api.fous.com/mcp -g -n fous \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Then ask your agent:# "Use Fous to run wikipedia.org/get_page_views# with {"topic":"Taylor Swift"}"Over HTTP, the answer’s data holds the output. A run still going after 30 seconds answers 202 with its id: ask GET /v1/runs/{id} until it ends.
Schema
Input schema
{ "type": "object", "required": [ "topic" ], "properties": { "topic": { "type": "string", "description": "The Wikipedia article name, such as Taylor Swift." }, "end_date": { "type": "string", "format": "date", "description": "Last date to count, inclusive, such as 2026-08-31. Defaults to yesterday." }, "group_by": { "enum": [ "day", "month" ], "type": "string", "default": "day", "description": "Group views by day or month, such as month. Defaults to day." }, "language": { "type": "string", "default": "English", "description": "Wikipedia language name or code, such as French or fr. Defaults to English." }, "start_date": { "type": "string", "format": "date", "description": "First date to count, inclusive, such as 2026-08-01. Defaults to 29 days before the end date." } }, "additionalProperties": false}Output schema
{ "type": "object", "required": [ "article_title", "article_link", "start_date", "end_date", "total_views", "average_views_per_day", "peak", "views" ], "properties": { "peak": { "type": [ "object", "null" ], "required": [ "date", "views" ], "properties": { "date": { "type": "string", "format": "date", "description": "Day, or first day of month." }, "views": { "type": "integer", "description": "Human-reader views." } }, "description": "Highest-view day or month in the selected period, or null if no counts are available.", "additionalProperties": false }, "views": { "type": "array", "items": { "type": "object", "required": [ "date", "views" ], "properties": { "date": { "type": "string", "format": "date" }, "views": { "type": "integer" } }, "additionalProperties": false }, "description": "Chronological daily or monthly reader views; monthly dates are the first of each month." }, "end_date": { "type": "string", "format": "date", "description": "Last day counted." }, "start_date": { "type": "string", "format": "date", "description": "First day counted." }, "total_views": { "type": "integer", "description": "Human-reader views during the period." }, "article_link": { "type": "string", "description": "Link to the article." }, "article_title": { "type": "string", "description": "Wikipedia article title." }, "average_views_per_day": { "type": "number", "description": "Total views divided by calendar days in the period." } }, "additionalProperties": false}- Price
- 1 credit per completed run (1¢ with pay as you go); failed runs are free.
- Method
wikipedia.org/get_page_views- Returns
- article title and link, date range, total views, average views per day, peak day or month, chronological views
Use it from your agent
Give your agent this line. It reads SKILL.md, gets a Fous API key and connects the Fous MCP server. Its run then takes the method wikipedia.org/get_page_views with the inputs above.
Ask your agent
- How many times was the Eiffel Tower Wikipedia article viewed by readers last month, broken down by day?
- Show monthly reader views for the article on the Great Barrier Reef from January to June 2025 in French Wikipedia.
- What was the peak day for views of the Marie Curie article over the past 30 days on Wikipedia?
- I need the average daily pageviews for the Bitcoin article between 2024-03-01 and 2024-03-31, plus the total.
- Give me the chronological monthly view counts for the Taylor Swift article on English Wikipedia for 2023 with the overall total.
See more
All Wikipedia methodsReturns the opening summary, short description, main image, article link and last edit time for a Wikipedia topic in the chosen language. For ambiguous names it uses the top matching article and lists up to five alternatives.
wikipedia.org/get_article_summaryReturns the full text of a Wikipedia article in ordered sections, with its last edit time, reference count and visible categories, in any language edition. Footnotes, tables and navigation material are excluded; a topic that is not an exact title uses the best search match.
wikipedia.org/get_full_articleReturns the labeled facts, in order, from the information box of a Wikipedia article in any language edition. Articles without an information box have no facts.
wikipedia.org/get_key_factsSearches a Wikipedia language edition by keywords and returns matching articles in relevance order, with descriptions, snippets, word counts, last edit dates and links.
wikipedia.org/search_articlesReturns Wikipedia's On this day events, births, deaths and holidays for a month and day, in a chosen Wikipedia language; events, births and deaths come newest year first.
wikipedia.org/get_on_this_dayFinds the best-matching Britannica encyclopedia article for a topic and returns its introduction, quick facts, section headings, update date and main image.
britannica.com/get_articleLists Wayback Machine captures of a web page, oldest first, with HTTP status and whether the content changed since the previous capture.
web.archive.org/list_snapshotsFinds a topic on the main English Fandom wiki for a franchise (picked from Fandom's cross-wiki search, or given as a wiki or article link) and returns the article's opening paragraphs, infobox facts, section headings, main image and links.
fandom.com/get_wiki_article