Skip to main content
Glama

CRAN MCP

A Model Context Protocol server that provides up-to-date R package documentation, package status information and R release information directly from CRAN.

The server is stateless: it fetches current CRAN pages on demand and returns only the relevant information to the MCP client.

Tools

  • search_packages(query, limit=20) searches all current CRAN package names and short descriptions and ranks matching packages.

  • get_package_info(package) returns the package title, description, current version, CRAN publication date and dependency groups (Depends, Imports, Suggests, LinkingTo, Enhances).

  • get_package_news(package, version=None, max_chars=50000) returns the package NEWS/changelog page from CRAN, optionally restricted to one version such as 1.18.4.

  • get_package_check_status(package) returns the current CRAN check status, status counts and results for every check flavor.

  • get_package_topics(package, query=None, limit=100) lists help topics from a CRAN package.

  • get_topic_documentation(package, topic, max_chars=30000) returns one help topic as plain text with its CRAN source URL.

  • search_package_documentation(package, query, limit=10) searches the reference manual and returns matching snippets.

  • get_r_versions(major=None, limit=100) lists R releases available from CRAN, optionally restricted to a major version such as 4.

  • get_r_version_news(version, max_chars=50000) returns the official R NEWS section for one R release, for example 4.5.1.

Related MCP server: mcp-server-npm

Package discovery

CRAN publishes one central list containing every currently available package together with its short description. search_packages() searches that list without downloading each package page individually.

Examples:

search_packages("survival model")
search_packages("arrow", limit=10)

R releases

get_r_versions() reads the official CRAN R source directories, so the version list is not hard-coded.

Examples:

get_r_versions()
get_r_versions(major=4)
get_r_version_news("4.5.1")

Local setup

uv sync --dev
uv run cran-mcp

The MCP endpoint is available at http://127.0.0.1:8000/mcp.

Docker

docker build -t cran-mcp .
docker run --rm -p 8000:8000 -e MCP_ALLOWED_HOSTS=localhost,localhost:* cran-mcp

Environment variables

  • PORT: HTTP port, default 8000.

  • MCP_ALLOWED_HOSTS: comma-separated allowed Host values for public deployment.

  • MCP_ALLOWED_ORIGINS: optional comma-separated allowed browser origins.

Examples

search_packages("Bayesian survival")
get_package_info("data.table")
get_package_news("data.table")
get_package_news("data.table", version="1.18.4")
get_package_check_status("data.table")
get_topic_documentation("data.table", "fread")
get_r_versions(major=4)
get_r_version_news("4.5.1")
MCP client
    |
    | package / R release request
    v
CRAN MCP
    |
    | HTTPS
    v
CRAN package index, package pages, NEWS, checks, R source index and HTML reference manuals
A
license - permissive license
-
quality - not tested
B
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

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

View all related MCP servers

Related MCP Connectors

  • MCP server for accessing curated awesome list documentation

  • MCP server for doc2mcp documentation, generated by doc2mcp.

  • MCP server for hex.pm and hexdocs.pm: search, inspect, compare, and audit Elixir packages

View all MCP Connectors

Latest Blog Posts

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/MEO265/cran_mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server