wikipedia
Wikipedia API for Python
What it is and what it does
Wikipedia is a lightweight wrapper around the MediaWiki API designed to make it simple to fetch and parse Wikipedia data from Python. It lets you search for articles, retrieve summaries and full page content, extract links and images, and switch between language editions—all without writing raw API calls. The library has no runtime dependencies and is intentionally minimal, trading advanced features for ease of use.
However, the package has been dormant since 2014-11-15, with no releases for years. While the GitHub repository remains active and received a commit on 2024-05-12, the long gap between the last release and today raises serious questions about whether it still works against the current MediaWiki API, whether it handles modern Python versions correctly, and whether it respects current infrastructure expectations.
Use it for:
- Quick prototyping or learning: fetch Wikipedia summaries and article text for educational scripts or demos without API overhead.
- Data collection for small projects: gather article links, references, or summaries for analysis when you don't need advanced scraping features.
- Multilingual content access: switch between language editions to retrieve the same article in different languages.
- Simple lookup tools: build a command-line or web tool that lets users search and read Wikipedia articles programmatically.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides simple Python access to Wikipedia article data through the MediaWiki API, enabling searches, summaries, links, and content retrieval without needing direct API knowledge.
No, unless you are working with legacy code or a frozen environment. The package is dormant (last release 2014-11-15), and its compatibility with current Python versions and the MediaWiki API is unverified. For new projects, seek a maintained alternative with active development and current API support. If you must use this library, test thoroughly in your environment first.
Install
wikipedia on PyPI
pip
pip install wikipediauv
uv add wikipediapoetry
poetry add wikipediaInstalling wikipedia
Before you install
High install friction with no runtime dependencies. The package is dormant—last release was 2014-11-15, with no new releases since then. While the repository remains on GitHub with 3004 stars and received a commit in 2024-05-12, the long gap between releases raises concerns about compatibility with modern Python versions and current MediaWiki infrastructure.
License in practice
MIT licensed under permissive terms, so you may use, modify, and distribute freely with minimal restrictions. No licensing barrier to adoption.
Quickstart
pip install wikipedia
import wikipedia
results = wikipedia.search("Python programming")
summary = wikipedia.summary("Python (programming language)")
page = wikipedia.page("Python (programming language)")
print(page.content)
The package's compatibility with current Python versions and MediaWiki API is uncertain given the maintenance gap; test against your target environment before relying on it in production.
Verify before relying
- Whether the package still works reliably against the current MediaWiki API without breaking changes.
- Confirmed compatibility with modern Python versions beyond the stated support range.
- Whether rate limiting or other infrastructure considerations have changed since the last release.
Package facts
| License | MIT (permissive) |
| Python support | not specified |
| Install friction | high — source build required |
| Runtime dependencies | none |
| Maintenance | dormant — 4,290 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 1,024,854/month — #4,483 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: wikipedia-1.4.0.tar.gz
Keywords: python, wikipedia, API
Tags
More Libraries packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
python-dateutilProvides parsing, arithmetic, and recurrence…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
mwclientmwclient is a Python client library for the…
permissive · top 15,000 on PyPI
pywikibotPywikibot is a Python framework that interfaces…
permissive · top 15,000 on PyPI
Wikipedia-APIWikipedia-API is a Python wrapper for…
permissive · top 5,000 on PyPI
lexisnexisapiProvides a Python interface to the LexisNexis…
permissive · top 15,000 on PyPI
mwparserfromhellParses MediaWiki wikicode into a queryable…
permissive · top 5,000 on PyPI
wikipedia-mcpExposes Wikipedia search, article retrieval,…
permissive · top 15,000 on PyPI
mwtypesProvides standardized Python classes for…
permissive · top 15,000 on PyPI
wikitextparserParses and manipulates MediaWiki wikitext…
copyleft · top 15,000 on PyPI
readable-contentExtracts the main article content from web…
permissive · top 15,000 on PyPI
mwxmlEfficiently parse and stream-process MediaWiki…
permissive · top 15,000 on PyPI