pyalex
Python interface to the OpenAlex database
What it is and what it does
PyAlex wraps the OpenAlex REST API, a free index of scholarly metadata (papers, authors, institutions, concepts, topics, publishers, funders). It provides a thin Python interface that mirrors the API's design, supporting entity retrieval by ID or DOI, filtering, full-text search, semantic similarity matching, grouping, pagination, and field selection. The library converts OpenAlex's inverted-index abstracts to plaintext on the fly and can fetch full-text content in PDF or TEI XML format where available.
Typical use is to query scholarly data programmatically—finding papers by topic or author, discovering similar works, aggregating publication statistics, or building research tools. It requires an OpenAlex API key (free) and depends only on requests and urllib3 for HTTP transport. The library is designed to stay close to the original API's structure, so developers familiar with OpenAlex's REST endpoints will find the Python calls intuitive.
Use it for:
- Query and filter scholarly papers by topic, author, institution, or open-access status for research surveys.
- Retrieve author profiles and publication histories to build researcher directories or impact dashboards.
- Find semantically similar papers to a given work or abstract using the semantic search endpoint.
- Download full-text content in PDF or TEI format for papers with open-access availability.
- Aggregate publication counts and metadata by institution, funder, or concept for bibliometric analysis.
- Autocomplete author, institution, or topic names in interactive research tools.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
PyAlex is a Python interface to the OpenAlex REST API, enabling programmatic access to hundreds of millions of scholarly papers, authors, institutions, and related metadata with support for filtering, searching, semantic similarity, and content retrieval.
Yes. PyAlex is a lightweight, actively maintained wrapper around a free, CC0-licensed scholarly database. Low install friction, no security vulnerabilities, permissive licensing, and broad Python version support (3.8–3.12) make it a straightforward choice for anyone building research tools, bibliometric dashboards, or academic data pipelines. The main gotcha is the required API key (free but mandatory as of February 2026), not a blocker for legitimate use.
Install
pyalex on PyPI
pip
pip install pyalexuv
uv add pyalexpoetry
poetry add pyalexInstalling pyalex
Before you install
Low friction: pure Python wheel with only requests and urllib3 as runtime dependencies. Active maintenance with a recent release as of 2026-02-23. Supports Python 3.8 through 3.12.
License in practice
MIT license (permissive). OpenAlex data itself is CC0 licensed, so combined use poses no licensing barrier for most academic and commercial applications.
Quickstart
pip install pyalex
import pyalex
pyalex.config.api_key = "<YOUR_API_KEY>"
from pyalex import Works
work = Works()["W2741809807"]
print(work["open_access"])
API key required as of February 13, 2026 (free account at openalex.org); without one, limited to 100 credits per day.
Verify before relying
- Exact number of scholarly records indexed by OpenAlex (described as 'hundreds of millions' but not quantified in fact sheet).
- Performance characteristics for large-scale queries or pagination across millions of results.
- Whether pipe operations and semantic search are fully stable or still experimental.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.8) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 2 — requests, urllib3 |
| Maintenance | actively maintained — 172 days since the last release |
| First released | |
| Downloads | 117,110/month — #12,180 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pyalex-0.21-py3-none-any.whl
Tags
More Information Analysis packages
A drop-in replacement for Python's standard…
permissive · top 100 on PyPI
pyarrowpyarrow provides Python bindings to Apache…
permissive · top 100 on PyPI
networkxNetworkX provides data structures and…
permissive · top 1,000 on PyPI
snowflake-connector-pythonConnects Python applications to Snowflake data…
permissive · top 1,000 on PyPI
contourpyContourPy calculates contours of 2D…
permissive · top 1,000 on PyPI
snowflake-snowpark-pythonSnowpark Python provides APIs to query and…
permissive · top 1,000 on PyPI
semanticscholarProvides a typed Python client for querying…
permissive · top 15,000 on PyPI
scholarlyscholarly retrieves author profiles,…
permissive · top 15,000 on PyPI
llama-index-vector-stores-faissIntegrates FAISS vector storage with LlamaIndex…
permissive · top 15,000 on PyPI
arxiv-mcp-serverAn MCP server that exposes arXiv search, paper…
permissive · top 15,000 on PyPI
libpysallibpysal provides core spatial analysis…
permissive · top 15,000 on PyPI
arxivProvides a Python interface to search, retrieve…
permissive · top 5,000 on PyPI
pymilvus.modelProvides embedding and reranker model…
permissive · top 15,000 on PyPI
SickleSickle is a lightweight Python client library…
permissive · top 15,000 on PyPI
habanerohabanero is a low-level Python client for the…
permissive · top 15,000 on PyPI
MDAnalysisMDAnalysis reads and analyzes molecular…
copyleft · top 15,000 on PyPI