---
title: Wendy for Foxglove
description: Stream a WendyOS device's live ROS 2 topics into Foxglove Studio for real-time visualization, with a single command and nothing to install on the device by hand.
---

Wendy for Foxglove turns a device's live ROS 2 graph into something you can *see*.
One command deploys the standard `foxglove_bridge` node to the device, joins it to
the device's ROS 2 graph, and forwards its WebSocket port to your machine. Every
topic in the selected domain, including hidden ROS topics, is exposed to Foxglove,
so you can drop a Raw Message panel, plot a signal, or watch a camera feed update
in real time.

```bash
wendy device foxglove serve
```

Then, in Foxglove Studio (desktop or [app.foxglove.dev](https://app.foxglove.dev)),
choose **Open connection** and enter:

```
ws://localhost:8765
```

Discovered topics appear as channels you can add to any panel.

<Callout type="warning">
Safari blocks the local `ws://` connection as mixed content when Foxglove runs
at `https://app.foxglove.dev`. Use Chrome for the web app, or use the Foxglove
desktop app.
</Callout>

## How it works

`wendy device foxglove serve` runs three steps for you:

1. **Generates a bridge app.** The CLI writes a temporary app: a Dockerfile based
   on `ros:<distro>` with the distro's `foxglove_bridge` package installed, and a
   `wendy.json` with a `frameworks.ros2` block (your `--domain`, `--rmw`, and
   `--distro`), `network`-scoped DDS discovery (loopback plus the device's
   network interface), and a host-network entitlement. This lets the bridge join
   the device's whole ROS 2 graph, including a robot's native host ROS 2 (for
   example a Unitree Go2's onboard stack).
2. **Deploys it.** Wendy builds and starts the bridge on your device under the
   app ID `sh.wendy.foxglovebridge`. Running the command again replaces it after
   the new build succeeds. An upgrade from an older bridge may require a brief
   interruption; the CLI prints a notice when that migration is needed.
3. **Forwards the port.** The bridge's WebSocket port (8765 inside the app) is
   forwarded over the same Wendy agent connection used for deployment. This
   works over LAN and cloud. The CLI checks the WebSocket handshake before
   printing the `ws://localhost:<port>` URL.

```
Foxglove Studio --ws--> localhost:8765 --tunnel--> foxglove_bridge (device) --DDS--> your ROS 2 apps
```

## Prerequisites

- A device reachable through Wendy over LAN or [Wendy Cloud](https://cloud.wendy.dev/login), with
  an agent that supports container exec. Forwarding reuses that connection.
- A supported image builder on your development machine: Docker, Apple
  Container, or BuildKit. Wendy uses the normal `wendy run` builder selection;
  pass `--builder` to choose one explicitly.
- A ROS 2 stack producing topics on the device (your own apps, or a robot's
  native ROS 2 reachable over the host network).

## Flags

| Flag | Description |
| --- | --- |
| `--port` | Local port to forward the bridge's WebSocket to (default `8765`). |
| `--domain` | `ROS_DOMAIN_ID` the device's ROS 2 uses (default `0`). |
| `--rmw` | RMW implementation the device's ROS 2 uses (default `rmw_cyclonedds_cpp`). |
| `--distro` | ROS 2 distro the bridge image is built from (default `humble`). |
| `--interface` | CycloneDDS network interface to use on a multi-interface device. The bridge still discovers apps on the same device over loopback. |
| `--builder` | Image builder to force: `docker`, `apple-container`, or `buildkit`. |

The global `--device` flag selects a device for both deployment and forwarding.
For example, to connect to a device on your LAN:

```bash
wendy device foxglove serve --device 192.0.2.10
```

Without `--device`, Wendy uses `WENDY_DEVICE`, the saved default, or the device
picker. It selects the device once for the whole command. Builder selection also
matches `wendy run`; for example, a Mac using Apple Container can run:

```bash
wendy device foxglove serve --builder apple-container
```

The bridge exposes every topic in the selected domain. ROS 2 domains are isolated
graphs, so stop and restart `serve` with a different `--domain` when you want to
inspect another graph.

The bridge uses the device's host network for ROS 2 discovery, but its WebSocket
listener binds only to `127.0.0.1` on the device. Foxglove therefore reaches the
bridge through the selected agent's container exec stream. The generated image
includes `socat` to relay the WebSocket bytes without a terminal. Port `8765`
is not exposed on the device's management or robot LAN.

<Callout type="warning">
**Match the bridge to your app's domain.** An app whose `frameworks.ros2` omits
`domainId` gets a stable auto-derived domain (a hash of its `appId`), not domain 0.
The bridge always uses an explicit domain (`--domain`, default 0), so for apps
using an auto-derived domain the bridge will not see their topics. The simplest
setup: set an explicit `domainId` in your app's `wendy.json` and pass the same
value with `--domain`.
</Callout>

For a robot whose ROS 2 runs on a non-default domain or middleware, match the
bridge to it:

```bash
wendy device foxglove serve --domain 42 --rmw rmw_cyclonedds_cpp
```

On a multi-interface robot, pin CycloneDDS to the interface connected to the
robot's native ROS 2 network. For example, a Unitree Go2 commonly uses its
`192.168.123.x` interface:

```bash
wendy device foxglove serve --domain 0 --interface enP8p1s0
```

The named interface carries outward discovery while loopback remains included,
so the bridge can also reach same-domain `device` apps on the host.

## Stopping and cleanup

Press **Ctrl-C** to stop the port forward. The bridge app keeps running detached
on the device. Run `serve` again at any time to redeploy and reconnect. To remove
the bridge from the device entirely:

```bash
wendy device apps remove sh.wendy.foxglovebridge --force --cleanup
```

## Related

- [Wendy for ROS 2](../../integrations/ros2/) lets you inspect, echo, and record
  the same ROS 2 data from the CLI.
- [Multi-app deployments](../../guides/multi-app-deployments/) shows how to deploy
  the ROS 2 stack the bridge visualizes.
