Skip to main content
Glama
hospital-ratings-cms-star-ratings-mcp

hospital-ratings-cms-star-ratings-mcp

hospital-ratings-cms-star-ratings-mcp

Hospital ratings for AI assistants: the CMS overall hospital star rating, patient survey (HCAHPS) stars, ER wait times and quality measures for every US hospital in Medicare Care Compare. Ask for the best rated hospitals in your city, how a hospital scores before surgery, or which of two hospitals has the shorter ER wait.

This is a Model Context Protocol (MCP) server. It reads the Medicare Care Compare hospital datasets that CMS publishes in the Provider Data Catalog on data.cms.gov at call time. It needs no API key.

Tools

Tool

What it returns

hospital_search

Hospitals in a state, city, county or ZIP code (or by name) with the CMS overall star rating, patient survey summary stars, type, ownership and ER availability, best rated first, with the count at each star level. Filters: hospital type, minimum stars, emergency services.

hospital_ratings

One hospital in full: overall star rating (or why it has none), mortality, safety and readmission measures better or worse than the national rate, patient survey stars overall and by topic, share rating it 9 or 10 and who would definitely recommend it against national, ER median time, left without being seen, sepsis care and staff flu vaccination against the state and national average.

hospital_compare

2 to 5 hospitals side by side on overall stars, patient stars, 9-10 ratings, ER median time, sepsis care and measure groups, with the leader on each.

Every result has structured JSON, a plain-text summary, as_of, source and more (a page on mcpstamp.com). Every tool is marked read-only.

Related MCP server: mcp-cms

What it knows that your model does not

  • The current CMS overall hospital star rating for each of the 5,435 hospitals in the October 2026 Care Compare data and the reason when a hospital is not rated, from the latest Care Compare refresh rather than a training-time snapshot.

  • Patient survey (HCAHPS) star ratings by topic and the share of patients who rated the hospital 9 or 10, compared with the national average.

  • Each hospital's ER median time from arrival to leaving and its rate of patients who left before being seen, against the state and national averages.

Install

Hosted (custom connector, ChatGPT developer mode, any remote MCP client)

Paste this URL. No token, no sign-up.

https://hospital-ratings-cms-star-ratings-mcp.lipmichal.workers.dev/mcp

Cursor

Add to ~/.cursor/mcp.json.

{
  "mcpServers": {
    "hospital-ratings": { "url": "https://hospital-ratings-cms-star-ratings-mcp.lipmichal.workers.dev/mcp" }
  }
}

VS Code

Add to .vscode/mcp.json.

{
  "servers": {
    "hospital-ratings": { "type": "http", "url": "https://hospital-ratings-cms-star-ratings-mcp.lipmichal.workers.dev/mcp" }
  }
}

Local stdio

The npm package is not published. Build it from this repository with Node 20 or newer, then point your MCP client at node /path/to/hospital-ratings-cms-star-ratings-mcp/dist/stdio.js.

git clone https://github.com/theluckystrike/hospital-ratings-cms-star-ratings-mcp && cd hospital-ratings-cms-star-ratings-mcp
npm install && npm run build
node dist/stdio.js

Example prompts

  • "What are the best rated hospitals in Boston?"

  • "How good is Mass General? What is its CMS star rating and ER wait time?"

  • "Compare Brigham and Women's and Massachusetts General Hospital for patient satisfaction."

  • "Which hospitals in Vermont with an emergency room have 4 or 5 stars?"

Data sources

Full list in DATA_SOURCES.md.

Limitations

  • US hospitals that report to Medicare only. Critical access, psychiatric, children's, cancer and DoD hospitals often have no overall star rating; the answer says why, using the CMS footnote.

  • Star ratings and measures cover past periods (patient survey and ER times for 2025 in the October 2026 refresh); CMS refreshes them quarterly.

  • Search is by state, city, county, ZIP code or ZIP prefix and name, not by distance.

  • Ratings are one input to choosing a hospital. Check the hospital on medicare.gov/care-compare and with a doctor.

More

More MCP servers that answer questions your assistant cannot answer alone are on mcpstamp.com.

Part of the Zovo MCP collection at https://mcp.zovo.one

Built by theluckystrike.

Development

npm install
npm test                              # builds, then runs the fixture tests and an offline stdio test
node scripts/stdio-transcript.mjs     # live stdio round trip, writes .live/stdio-transcript.jsonl

CI (.github/workflows/bundle.yml) runs the tests, the type check and wrangler deploy --dry-run --outdir out, and uploads the Worker bundle as an artifact.

License

MIT

Available Tools

3 tools
hospital_compareCompare hospitalsA
Read-onlyIdempotent
Inspect

Compare 2 to 5 hospitals side by side on CMS overall stars, patient survey stars, the share of patients rating it 9 or 10 and who would recommend it, ER median time, left before being seen, sepsis care and mortality, safety and readmission measures better or worse than national. Names which hospital leads each.

Inputs: hospitals (required).

hospital_ratingsHospital star rating and quality detailA
Read-onlyIdempotent
Inspect

Full CMS Care Compare ratings for one hospital (by facility id, or name with state or city): overall star rating with the reason when unrated; how many mortality, safety and readmission measures are better, no different or worse than the national rate; HCAHPS patient survey stars overall and by topic (nurses, doctors, cleanliness, quiet, discharge), share rating it 9 or 10 and who would recommend it against national; ER median time from arrival to leaving, left without being seen, sepsis care and staff flu vaccination, each against the state and national average.

Inputs: city, name, state, facility_id.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4/5.0

    Scored across 3 tools

    Disambiguation5/5

    The three tools have clearly distinct roles: hospital_search finds hospitals and returns summary ratings, hospital_ratings retrieves full detail for one hospital, and hospital_compare compares 2-5 hospitals side by side. The search-versus-detail boundary is natural and well explained, so an agent should select the correct tool reliably.

    Naming Consistency5/5

    All tools use the same snake_case pattern with the hospital_ prefix followed by a clear action or content descriptor. The convention is predictable across the entire small tool set.

    Tool Count5/5

    Three tools is a well-scoped surface for a focused hospital ratings lookup server: discovery, detailed lookup, and comparison. Each tool earns its place without redundancy.

    Completeness4/5

    The core lifecycle for a read-only ratings domain is covered: search, retrieve full ratings, and compare multiple hospitals. Minor gaps might include explicit enumeration of valid hospital types or filter options, but agents can work around these from the descriptions.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI agents to discover, inspect, and query CMS open datasets covering Medicare/Medicaid provider, spending, enrollment, drug pricing, quality, hospital, nursing home, and ACO data. Supports keyword search, metadata lookup, paged row retrieval, full-text search, and exact-match column filters.
      66 npm
      1
      MIT
    • A
      license
      Not graded
      quality
      A
      maintenance
      Enables AI assistants to query authoritative sources like FDA, WHO, PubMed, RxNorm, and Google Scholar for drug information, health statistics, clinical guidelines, trials, and medical literature. It runs locally with no API keys, so data stays private while results come back with evidence grading and resilient fallbacks.
      74 npm
      ISC
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI agents to look up what US hospitals charge for a CPT/HCPCS or MS-DRG code near a ZIP — gross charge, discounted self-pay price, and de-identified payer-negotiated rates — sourced from the standard charges files hospitals publish under the CMS price transparency rule. Also compares up to 10 hospitals side by side by CMS Certification Number and reports whether a given hospital's prices are held, and why not, when they aren't.
      51 npm
      MIT