# ROS2 MCP

> Let AI agents inspect and operate ROS 2 robots through MCP.

- **URL**: https://followmcp.com/en/servers/ros2-mcp
- **Category**: Other
- **Origin**: Community
- **Stars**: 100
- **FMRS Score**: 56/100 (Grade C)
- **Source**: https://github.com/wise-vision/ros2_mcp
- **Transports**: stdio (local process), Streamable HTTP, SSE
- **Runtimes**: Docker, Python 3.10+
- **Auth**: No credential needed

## Overview
ROS2 MCP is an MPL-2.0 open-source MCP server that connects directly to the ROS 2 graph through rclpy. It can discover, subscribe to, and publish on topics; call services and actions; and view maps, point clouds, and historical messages. It supports ROS 2 Humble and Jazzy. stdio is the default transport; Streamable HTTP and deprecated SSE are also supported. Read-only mode removes tools that can change robot state.

## Best for
- Developers using ROS 2 Humble or Jazzy who want an MCP client to inspect live robot data.
- Teams that want to restrict state-changing tools with read-only mode.
- Use cases where clients need images, maps, or point clouds returned as PNG.

## Not for
- ROS 1 systems; the README explicitly says ROS 1 is not supported.
- Users who need dedicated node or parameter tools; the README says these are not currently available.
- Users needing support guarantees for untested or unshipped distributions such as Iron, Kilted, or Rolling.
- Deployments that require the server to run away from the robot and connect only through rosbridge.

## Required permissions
- The server needs access to the ROS 2 graph; Docker deployments may need network configuration for DDS discovery.
- In the default mode, registered tools can publish topics, call services, and send or cancel action goals.
- Set ROS2_MCP_READONLY=1 to keep state-changing tools from being registered.
- An optional ~/mcp_custom_messages:/app/custom_msgs mount supplies a custom messages directory.

## Risks
- Publishing, service calls, and action tools may change real robot state. Discover interfaces and confirm fields first; use small values and short durations.
- Streamable HTTP has no built-in authentication. Anyone who can reach the port can use tools, including publishing tools. Keep it on loopback or a private network, or put an authenticated reverse proxy in front of wider access.
- DDS discovery may be incomplete immediately after a Docker container starts, so the first list may be partial.

## Tools (24)
- `ros2_topic_list`: List ROS 2 topics.
- `ros2_service_list`: List ROS 2 services.
- `ros2_list_actions`: List ROS 2 actions.
- `ros2_interface_list`: List ROS 2 interfaces.
- `ros2_get_message_fields`: Show the field names and types for a message type.
- `ros2_topic_subscribe`: Subscribe to a ROS 2 topic and read messages.
- `ros2_subscribe_multiple_topics`: Subscribe to multiple topics; images are returned as PNG.
- `ros2_topic_publish`: Publish a message to a ROS 2 topic; this may change robot state.
- `ros2_publish_multiple_topics`: Publish to multiple ROS 2 topics with a configurable frequency and duration; this may change robot state.
- `ros2_service_call`: Call a ROS 2 service; the service may have side effects.
- `ros2_send_action_goal`: Send a ROS 2 action goal, optionally waiting for its result; this may change robot state.
- `ros2_action_request_result`: Request a ROS 2 action result.
- `ros2_action_subscribe_feedback`: Subscribe to ROS 2 action feedback.
- `ros2_action_subscribe_status`: Subscribe to ROS 2 action status.
- `ros2_cancel_action_goal`: Cancel a ROS 2 action goal; this affects an active action.
- `ros2_get_map_as_image`: Convert an OccupancyGrid map to PNG.
- `ros2_get_pointcloud_as_bev`: Convert a PointCloud2 point cloud to a bird's-eye-view PNG.
- `ros2_get_messages_stored_in_influx_data_base`: Retrieve historical messages from the WiseVision Data Black Box.
- `ros2_viewer_app`: Open an interactive image, point cloud, or plot viewer.
- `ros2_viewer_config`: Configure the viewer.
- `ros2_stream_start`: Start a viewer data stream.
- `ros2_stream_next`: Read the next item in a data stream.
- `ros2_stream_next_image`: Read the next image in a data stream.
- `ros2_stream_stop`: Stop a data stream.
