Headless PyMOL for molecular visualization, GROMACS/LAMMPS MD trajectories, and clathrate-hydrate cage analysis: H-bond networks, F3/F4 order parameters, and TRACE cage perception + occupancy.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent — or use 1-click editor setup below.
One-click editor setup isn’t available for this listing yet — we don’t have a confirmed install command, and we’d rather show nothing than point your editor at the wrong package or host. Follow the project’s own setup instructions, linked above.

Headless PyMOL as an MCP server — drive molecular visualization, GROMACS/LAMMPS trajectories, and clathrate-hydrate cage science from your LLM.
Demo · Quick Start · Highlights · Features · Tools · Cage Science · 한국어
[!NOTE] An MCP server that embeds PyMOL in-process, headless — no GUI, no socket plugin, no manual setup. It exposes 30+ typed tools, returns rendered images inline so the model can see what it draws, loads GROMACS/LAMMPS trajectories, and ships a clathrate-hydrate analysis toolkit (H-bond networks, F3/F4 order parameters) with numerically validated science.

Ask in plain language → the model calls typed tools → headless PyMOL renders it. (full-quality MP4)
| Runtime | Embedded, headless pymol2 — no GUI, no plugin, no socket |
| Tools | 30+ typed tools with real, structured return values |
| Vision | ray-traced PNG returned inline so the model sees what it draws |
| MD trajectories | GROMACS .xtc/.trr + LAMMPS dump (MDAnalysis bridge) |
| Domain science | cage perception (TRACE), occupancy, H-bonds, F3/F4 — validated |
| Robustness | worker-thread session, stdout-safe transport, pytest suite |
| Safety | arbitrary-code passthrough off by default |
| Directory | Glama (wjgoarxiv/pymol-mcp, release v0.1.0) and awesome-mcp-servers Biology (PR #9110, merged) |
render_image ray-traces and returns a PNG as MCP image content. Use ray_style="pymolwiki_color" for the PyMOLWiki quantized-color outline profile..gro+.xtc, or bridge LAMMPS/NetCDF/… through MDAnalysis with in-memory coordinate injection.PYMOL_MCP_ALLOW_CODE_EXEC=1).[!IMPORTANT] PyMOL open-source is a conda package, and the server must run in a Python that can
import pymol2. Install into that interpreter — do not useuvx/fastmcp install(they build isolated envs without PyMOL).
It's a standard MCP server over stdio, so it works with any MCP-capable client (Claude Code / Desktop,
Codex CLI, Gemini CLI, Cline, Continue, …). Point the command at the absolute conda interpreter so it
can import pymol2.
Most clients use an mcpServers block (Claude Code / Desktop, Gemini CLI, Cline, Continue, …):
~/.codex/config.tomlPrefer not to hardcode a path? Use "command": "conda", "args": ["run", "-n", "pymol-mcp", "python", "-m", "pymol_mcp"] instead (requires conda on the client's PATH). See llms-install.md for a full from-scratch setup.
To enable the opt-in scripting tools, add "env": {"PYMOL_MCP_ALLOW_CODE_EXEC": "1"} to the server entry.
Then ask your agent things like:
| Group | Tools |
|---|---|
| Session / IO | load_structure · fetch_pdb · list_objects · get_object_info · reset_session |
| Selection | select · get_selection_info |
| Representation | show · hide · color · spectrum · set_background |
| View / Render | orient · zoom · turn · set_projection · render_image → 🖼️ inline PNG |
| Measurement | measure_distance · measure_angle · measure_dihedral · align · save_file |
| Trajectory / MD | load_trajectory (GROMACS/DCD) · load_trajectory_mda (LAMMPS/NetCDF via MDAnalysis) |
| Clathrate domain | identify_cages (TRACE) · cage_occupancy · mark_cages · hbond_network · order_parameter (F3 / F4) · chill_plus · mark_chill_plus |
| Scripting (opt-in) | run_pml · run_python |
render_image accepts a fixed ray_style profile. If you omit it, the tool uses pymolwiki_outline.
Use ray_style="default" explicitly to preserve the current PyMOL settings.
| Profile | PyMOL setting | Use |
|---|---|---|
default | unchanged | Preserve the current scene style |
pymolwiki_outline | ray_trace_mode=1 | Color with black outlines |
pymolwiki_bw | ray_trace_mode=2 | Black-and-white outline mode |
pymolwiki_color | ray_trace_mode=3 | Quantized color with black outlines |
The PyMOLWiki profiles set antialiasing to 2. They use the built-in PyMOL ray tracer. They restore the previous ray settings after each render. Set a white background for the closest match to the PyMOLWiki examples.
set_projection switches the camera between orthographic (parallel cage edges, typical publication lattice) and perspective. PyMOL's default field of view is 20°; raise it (e.g. 40) to make depth obvious. save_file writes a PNG/PDB/PSE to disk and creates missing parent directories. list_objects includes CGO overlays such as cages and chill_plus.
Ported from a validated Rust reference implementation and re-checked against ground truth. All analysis runs in
nanometres with a correct fractional-coordinate minimum-image convention (orthorhombic and triclinic),
a signed atan2 dihedral for F4, and a periodic-image KDTree for neighbour search.
No reviews yet — be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/wjgoarxiv-pymol-mcp)<a href="https://allmcps.com/mcp/wjgoarxiv-pymol-mcp"><img src="https://allmcps.com/api/badge/wjgoarxiv-pymol-mcp?style=directory" alt="Pymol MCP on AllMCPs" /></a>