arxiv-mcp-server
Provides tools to search arXiv papers, fetch metadata, read full-text content, and list category taxonomy, enabling AI agents to access and analyze academic papers from arXiv.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@arxiv-mcp-serversearch for the latest papers on large language models"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Public Hosted Server: https://arxiv.caseyjhand.com/mcp
Tools
Four tools for searching and reading arXiv papers:
Tool Name | Description |
| Search arXiv papers by query with category and sort filters. |
| Get full metadata for one or more arXiv papers by ID. |
| Fetch the full text content of an arXiv paper from its HTML rendering, or from the PDF when no render exists. |
| List arXiv category taxonomy, optionally filtered by group. |
arxiv_search
Search for papers using free-text queries with field prefixes and boolean operators.
Field prefixes:
ti:(title),au:(author),abs:(abstract),cat:(category),all:(all fields)Boolean operators:
AND,OR,ANDNOTOptional category filter, sorting (relevance, submitted, updated), and pagination
Category accepts a leaf code (
cs.CL) or a whole archive (astro-ph,cs,math) — a bare archive covers its subject classes plus the legacy flat papers filed before it was subdividedsubmitted_from/submitted_tobound the submission date (inclusive, UTCYYYY-MM-DD). Consecutive windows cover the matches with no gap — a paper submitted exactly at a midnight seam falls in both, so de-duplicate by ID — which is how to reach results past the 10,000 pagination ceilingEchoes back the query as actually searched, with every filter folded in — replaying it reproduces the same result set
Returns up to 50 results per request with full metadata including abstract
arxiv_get_metadata
Fetch full metadata for one or more papers by known arXiv ID.
Batch fetch up to 10 papers in a single request
Accepts both versioned (
2401.12345v2) and unversioned (2401.12345) IDsLegacy ID format supported (
hep-th/9901001)Reports not-found IDs separately from found papers
arxiv_read_paper
Read the full body of an arXiv paper.
Tries native arXiv HTML first, then ar5iv, then text extracted from the PDF — the
sourcefield reports which one answeredStrips HTML head/boilerplate and collapses MathML to dollar-delimited LaTeX (
$…$inline,$$…$$block) so the character budget targets paper contentReturns raw HTML — no parsing or extraction; the LLM interprets content directly. PDF-extracted bodies are plain text: prose is reliable, but math, tables, and heading structure flatten
max_charactersdefaults to 100,000; passnullfor the whole paper in one call. Raw HTML can be 500KB-3MB+ for math-heavy papers, which is more than most clients accept in a single tool result — page withstartinstead
arxiv_list_categories
List arXiv category codes and names for discovery.
~155 categories across 8 top-level groups (cs, math, physics, q-bio, q-fin, stat, eess, econ)
Optional group filter to narrow results
Static data — always succeeds
Related MCP server: Research Server
Resources
URI Pattern | Description |
| Paper metadata by arXiv ID. Percent-encode a legacy ID's slash — |
| Full arXiv category taxonomy. |
Features
Built on @cyanheads/mcp-ts-core:
Declarative tool definitions — single file per tool, framework handles registration and validation
Unified error handling across all tools
Pluggable auth (
none,jwt,oauth)Structured logging with optional OpenTelemetry tracing
Runs locally (stdio/HTTP) from the same codebase
arXiv-specific:
Read-only, no authentication required — arXiv API is free, metadata is CC0
Rate-limited request queue enforcing arXiv's 3-second crawl delay
Adaptive cooldown on rate-limit (5s → 10s → 20s → 30s), honors
Retry-AfterRetry with exponential backoff for transient failures
Content fallback chain: native arXiv HTML → ar5iv → PDF text extraction (both HTML renders run LaTeXML, so they tend to fail together; the PDF is the artifact every paper has, and it also covers an ar5iv outage rather than letting one fail the read)
Full arXiv category taxonomy embedded as static data
Optional local OAI-PMH metadata mirror (SQLite + FTS5) — opt-in, eliminates rate-limit exposure for
arxiv_searchandarxiv_get_metadata. See Optional: Local Mirror.
Getting Started
Public Hosted Instance
A public instance is available at https://arxiv.caseyjhand.com/mcp — no installation required. Point any MCP client at it via Streamable HTTP:
{
"mcpServers": {
"arxiv-mcp-server": {
"type": "streamable-http",
"url": "https://arxiv.caseyjhand.com/mcp"
}
}
}Self-Hosted / Local
Add to your MCP client config (e.g., claude_desktop_config.json):
{
"mcpServers": {
"arxiv-mcp-server": {
"type": "stdio",
"command": "bunx",
"args": ["@cyanheads/arxiv-mcp-server@latest"]
}
}
}Prerequisites
Bun v1.3.0 or higher.
Installation
Clone the repository:
git clone https://github.com/cyanheads/arxiv-mcp-server.gitNavigate into the directory:
cd arxiv-mcp-serverInstall dependencies:
bun installConfiguration
All configuration is optional — the server works out of the box with sensible defaults.
Variable | Description | Default |
| arXiv API base URL. |
|
| Minimum delay between arXiv API requests (ms). |
|
| Timeout for paper body fetches — HTML renders and PDF downloads (ms). |
|
| Timeout for API search/metadata requests (ms). |
|
| Enable local OAI-PMH metadata mirror for search and metadata. |
|
| SQLite path for the mirror. |
|
| UTC cron expression for in-process daily refresh (HTTP mode only). | unset |
| Fall through to live API on local ID-lookup miss. |
|
| Route |
|
| arXiv OAI-PMH endpoint base URL. |
|
| Minimum delay between OAI-PMH requests (ms). |
|
| Abort budget for one scheduled refresh subprocess (ms). |
|
| Transport: |
|
| Port for HTTP server. |
|
| Auth mode: |
|
| Log level (RFC 5424). |
|
Running the Server
Local Development
Build and run:
bun run build bun run start:http # or start:stdioRun checks and tests:
bun run devcheck # Lint, format, typecheck, audit bun run test # Vitest
Optional: Local Mirror
For self-hosted deployments behind a single egress IP, arXiv's ~3-second per-IP crawl delay serializes concurrent users. An optional local mirror eliminates rate-limit exposure for arxiv_search and arxiv_get_metadata by serving from a SQLite + FTS5 store harvested via OAI-PMH. arxiv_read_paper continues to use the live API — full-content harvest is forbidden by arXiv's data policy.
Disabled by default. To enable:
# 1. Cold-start harvest (~4.4h sequential, resumable from checkpoint). One-time per installation.
bun run mirror:init
# 2. Enable the mirror.
export ARXIV_MIRROR_ENABLED=true
# 3. Start the server — reads switch to the mirror once the harvest completes.
bun run start:httpDaily incremental refresh (small delta; duration depends on arXiv's OAI-PMH page pacing) via:
bun run mirror:refresh # wire to cron / systemd timer / launchd, OR
# set ARXIV_MIRROR_REFRESH_CRON to schedule it in HTTP mode (spawned as a child process)
bun run mirror:verify # schema version + PRAGMA integrity_check / quick_checkSchema upgrades. The mirror records a schema version and migrates itself in place the first time a newer server opens it — never a re-harvest, and never a separate operator step. The upgrade that added comment and journal_ref to the full-text index (#37) rebuilds that index from the rows already stored, so co: and jr: searches resolve against a mirror harvested before it. The rebuild runs at startup, before the store answers its first read, and logs mirror migration v2→v3 (fts rebuild) progress lines throughout — on a full-corpus mirror, expect the first start after the upgrade to take noticeably longer than usual. An interrupted rebuild is repeated on the next open rather than left half-applied. bun run mirror:verify prints the schema version the file carries and exits non-zero if a migration never completed.
Behavior notes. Ranking divergence: FTS5 BM25 differs from arXiv's internal ranking, so sortBy=relevance against the mirror returns a different top-K than the live API. Queries sorted by submitted descending within ARXIV_MIRROR_RECENT_DAYS_LIVE days route to the live API to cover the nightly-update gap. Refresh resilience: after the initial cold harvest completes, an in-progress or failed daily refresh keeps serving the existing dataset from the mirror — arxiv_search and arxiv_get_metadata don't drop to the live API during the refresh window (#21). The scheduled HTTP-mode refresh runs in a child process, so the harvest's synchronous SQLite writes never block the request event loop — search and metadata stay responsive throughout (#22). The mirror stores the latest version only; per-version reads continue to use the live API. See #12 for the full design.
Docker
docker build -t arxiv-mcp-server .
docker run -p 3010:3010 arxiv-mcp-serverProject Structure
Directory | Purpose |
| Tool definitions ( |
| Resource definitions ( |
|
|
| Optional OAI-PMH mirror — harvester, SQLite + FTS5 store, query translator, runner. |
| Environment variable parsing and validation with Zod. |
| Mirror lifecycle scripts ( |
| Unit and integration tests. |
| Design document and directory structure. |
Development Guide
See CLAUDE.md for development guidelines and architectural rules. The short version:
Handlers throw, framework catches — no
try/catchin tool logicUse
ctx.logfor domain-specific loggingRate limiting is managed by
ArxivService— don't add per-tool delaysarXiv API returns HTTP 200 for everything — check content-type and response body
Contributing
Issues and pull requests are welcome. Run checks before submitting:
bun run devcheck
bun testLicense
Apache-2.0 — see LICENSE for details.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseBquality-maintenanceEnables AI assistants to search and retrieve academic papers from arXiv through MCP tools, supporting search by various criteria, detailed paper information, category browsing, and PDF content extraction.Last updated41052
- FlicenseBqualityCmaintenanceEnables searching arXiv papers and retrieving paper metadata through MCP tools.Last updated2
- AlicenseAqualityDmaintenanceMCP server for searching, retrieving, and extracting full-text PDFs from arXiv papers.Last updated523MIT
- AlicenseAqualityBmaintenanceMCP server for searching and retrieving arXiv papers with full-text PDF extraction.Last updated53MIT
Related MCP Connectors
Search arXiv/Semantic Scholar/OpenAlex + medical evidence (PubMed/Europe PMC) + LaTeX/PDF tools.
Search and download academic papers from arXiv, PubMed, bioRxiv, medRxiv, Google Scholar, Semantic…
Find academic papers across major sources like arXiv, PubMed, bioRxiv, and more. Download PDFs whe…
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/cyanheads/arxiv-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server