Skip to content
Back to search

PubMed-MCP-Server

πŸ” Enable AI assistants to search, access, and analyze PubMed articles through a simple MCP interface.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/jackkuo666--pubmed-mcp-server/badge.svg)](/listings/jackkuo666--pubmed-mcp-server)

HTML

<a href="/listings/jackkuo666--pubmed-mcp-server"><img src="/api/listings/jackkuo666--pubmed-mcp-server/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Prerequisites

- Python 3.10+ - FastMCP library

Installation

Installing via Smithery

To install pubmed-mcp-server for Claude Desktop automatically via [Smithery](https://smithery.ai/server/@JackKuo666/pubmed-mcp-server):

claude

npx -y @smithery/cli install @JackKuo666/pubmed-mcp-server --client claude

Cursor

Paste the following into Settings β†’ Cursor Settings β†’ MCP β†’ Add new server: - Mac/Linux

npx -y @smithery/cli@latest run @JackKuo666/pubmed-mcp-server --client cursor --config "{}" 

Windsurf

npx -y @smithery/cli@latest install @JackKuo666/pubmed-mcp-server --client windsurf --config "{}"

CLine

npx -y @smithery/cli@latest install @JackKuo666/pubmed-mcp-server --client cline --config "{}"

1. Clone the repository:

   git clone https://github.com/JackKuo666/PubMed-MCP-Server.git
   cd PubMed-MCP-Server

2. Install the required dependencies:

   pip install -r requirements.txt

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md Β· README Β· 181 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. [![MseeP.ai Security Assessment Badge](https://mseep.net/pr/jackkuo666-pubmed-mcp-server-badge.png)](https://mseep.ai/app/jackkuo666-pubmed-mcp-server)
  2. # PubMed MCP Server
  3. [![smithery badge](https://smithery.ai/badge/@JackKuo666/pubmed-mcp-server)](https://smithery.ai/server/@JackKuo666/pubmed-mcp-server)
  4. πŸ” Enable AI assistants to search, access, and analyze PubMed articles through a simple MCP interface.
  5. The PubMed MCP Server provides a bridge between AI assistants and PubMed's vast repository of biomedical literature through the Model Context Protocol (MCP). It allows AI models to search for scientific articles, access their metadata, and perform deep analysis in a programmatic way.
  6. 🀝 Contribute β€’ πŸ“ Report Bug
  7. ## ✨ Core Features
  8. - πŸ”Ž Paper Search: Query PubMed articles with keywords or advanced search βœ…
  9. - πŸš€ Efficient Retrieval: Fast access to paper metadata βœ…
  10. - πŸ“Š Metadata Access: Retrieve detailed metadata for specific papers βœ…
  11. - πŸ“Š Research Support: Facilitate biomedical sciences research and analysis βœ…
  12. - πŸ“„ Paper Access: Attempt to download full-text PDF content βœ…
  13. - 🧠 Deep Analysis: Perform comprehensive analysis of papers βœ…
  14. - πŸ“ Research Prompts: A set of specialized prompts for paper analysis βœ…
  15. ## πŸš€ Quick Start
  16. ### Prerequisites
  17. - Python 3.10+
  18. - FastMCP library
  19. ### Installation
  20. ### Installing via Smithery
  21. To install pubmed-mcp-server for Claude Desktop automatically via [Smithery](https://smithery.ai/server/@JackKuo666/pubmed-mcp-server):
  22. #### claude
  23. ```bash
  24. npx -y @smithery/cli install @JackKuo666/pubmed-mcp-server --client claude
  25. ```
  26. #### Cursor
  27. Paste the following into Settings β†’ Cursor Settings β†’ MCP β†’ Add new server:
  28. - Mac/Linux
  29. ```s
  30. npx -y @smithery/cli@latest run @JackKuo666/pubmed-mcp-server --client cursor --config "{}"
  31. ```
  32. #### Windsurf
  33. ```sh
  34. npx -y @smithery/cli@latest install @JackKuo666/pubmed-mcp-server --client windsurf --config "{}"
  35. ```
  36. ### CLine
  37. ```sh
  38. npx -y @smithery/cli@latest install @JackKuo666/pubmed-mcp-server --client cline --config "{}"
  39. ```
  40. 1. Clone the repository:
  41. ```
  42. git clone https://github.com/JackKuo666/PubMed-MCP-Server.git
  43. cd PubMed-MCP-Server
  44. ```
  45. 2. Install the required dependencies:
  46. ```
  47. pip install -r requirements.txt
  48. ```
  49. ## πŸ“Š Usage
  50. Start the MCP server:
  51. ```bash
  52. python pubmed_server.py
  53. ```
  54. ## Usage with Claude Desktop
  55. Add this configuration to your `claude_desktop_config.json`:
  56. (Mac OS)
  57. ```json
  58. {
  59. "mcpServers": {
  60. "pubmed": {
  61. "command": "python",
  62. "args": ["-m", "pubmed-mcp-server"]
  63. }
  64. }
  65. }
  66. ```
  67. (Windows version):
  68. ```json
  69. {
  70. "mcpServers": {
  71. "pubmed": {
  72. "command": "C:\\Users\\YOUR\\PATH\\miniconda3\\envs\\mcp_server\\python.exe",
  73. "args": [
  74. "D:\\code\\YOUR\\PATH\\PubMed-MCP-Server\\pubmed_server.py"
  75. ],
  76. "env": {},
  77. "disabled": false,
  78. "autoApprove": []
  79. }
  80. }
  81. }
  82. ```
  83. Using with Cline
  84. ```json
  85. {
  86. "mcpServers": {
  87. "pubmed": {
  88. "command": "bash",
  89. "args": [
  90. "-c",
  91. "source /home/YOUR/PATH/mcp-server-pubmed/.venv/bin/activate && python /home/YOUR/PATH/pubmed-mcp-server.py"
  92. ],
  93. "env": {},
  94. "disabled": false,
  95. "autoApprove": []
  96. }
  97. }
  98. }
  99. ```
  100. ## πŸ›  MCP Tools
  101. The PubMed MCP Server provides the following tools:
  102. 1. `search_pubmed_key_words`: Search for articles on PubMed using keywords.
  103. 2. `search_pubmed_advanced`: Perform an advanced search for articles on PubMed with multiple parameters.
  104. 3. `get_pubmed_article_metadata`: Fetch metadata for a PubMed article using its PMID.
  105. 4. `download_pubmed_pdf`: Attempt to download the full-text PDF for a PubMed article.
  106. 5. `deep_paper_analysis`: Perform a comprehensive analysis of a PubMed article.
  107. ### Searching Papers
  108. You can ask the AI assistant to search for papers using queries like:
  109. ```
  110. Can you search PubMed for recent papers about CRISPR?
  111. ```
  112. ### Getting Paper Details
  113. Once you have a PMID, you can ask for more details:
  114. ```
  115. Can you show me the metadata for the paper with PMID 12345678?
  116. ```
  117. ### Analyzing Papers
  118. You can request a deep analysis of a paper:
  119. ```
  120. Can you perform a deep analysis of the paper with PMID 12345678?
  121. ```
  122. ## πŸ“ Project Structure
  123. - `pubmed_server.py`: The main MCP server implementation using FastMCP
  124. - `pubmed_web_search.py`: Contains the logic for searching PubMed and retrieving article information
  125. ## πŸ”§ Dependencies
  126. - Python 3.10+
  127. - FastMCP
  128. - asyncio
  129. - logging
  130. - requests
  131. - beautifulsoup4
  132. ## 🀝 Contributing
  133. Contributions are welcome! Please feel free to submit a Pull Request.
  134. ## πŸ“„ License
  135. This project is licensed under the MIT License.
  136. ## ⚠️ Disclaimer
  137. This tool is for research purposes only. Please respect PubMed's terms of service and use this tool responsibly.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.