How to debug the DeepSeek Harness desktop app: DSH_DESKTOP

Configuration & UsagePublished 2026-10-02Author: DeepSeek Plugin Market
DeepSeek HarnessDSH plugindesktop appdebuggingDevTools
The DeepSeek Harness desktop app opens debug ports via three DSH_DESKTOP variables: main 9229, renderer 9222 and host 9230, plus DSH_DESKTOP_OPEN_DEVTOOLS.

The DeepSeek Harness desktop app opens debug ports through three environment variables: DSH_DESKTOP_MAIN_INSPECT_PORT (default 9229, main process), DSH_DESKTOP_RENDERER_DEBUG_PORT (default 9222, renderer) and DSH_DESKTOP_HOST_INSPECT_PORT (default 9230, host process), plus DSH_DESKTOP_OPEN_DEVTOOLS for developer tools. This guide covers the port roles, how to open DevTools and how to run in development mode.

Which debug ports the DeepSeek Harness desktop app has: three DSH_DESKTOP variables

The DeepSeek Harness desktop app has three debug port variables: DSH_DESKTOP_MAIN_INSPECT_PORT (default 9229), DSH_DESKTOP_RENDERER_DEBUG_PORT (default 9222) and DSH_DESKTOP_HOST_INSPECT_PORT (default 9230) (source). One by one:

  1. DSH_DESKTOP_MAIN_INSPECT_PORT (9229) — the main-process debug port. Expected: attach a main-process debugger to diagnose window and lifecycle issues.
  2. DSH_DESKTOP_RENDERER_DEBUG_PORT (9222) — the renderer debug port. Expected: the interface layer's console and network requests show up here.
  3. DSH_DESKTOP_HOST_INSPECT_PORT (9230) — the host-process debug port. Expected: diagnose the process carrying host logic.
  4. Change ports as needed — when a default port is taken, export the same-named variable before launch. Expected: switching to a free port resolves it.
  5. Open only what you need — for interface issues alone, start with 9222. Expected: no need to open all three.

How to open DevTools and development mode in the DeepSeek Harness desktop app

Use DSH_DESKTOP_OPEN_DEVTOOLS to control whether developer tools open automatically; start development mode in the repository with pnpm run dev:desktop (source). Follow these steps:

  1. Set the DevTools switch — set DSH_DESKTOP_OPEN_DEVTOOLS before launching. Expected: useful when the interface debug panel should open automatically.
  2. Launch a debug instance — start the desktop app with the port variables above. Expected: the debug ports begin listening.
  3. Attach a debugger — connect to the main process on 9229 and inspect the interface on the renderer port 9222. Expected: you can see the console and network in DevTools.
  4. Run in development mode — run pnpm run dev:desktop from source. Expected: code changes reflect immediately, which suits diagnosing the desktop shell and plugin loading.
  5. Reset the variables — clear the temporary variables when done. Expected: everyday use should not leave debug ports open.

When debugging how DSH plugins load in the desktop app, first confirm with the DSH Plugin Hub that the plugin is installed in the desktop profile.

Installed DSH plugins

How the DeepSeek Harness desktop debug ports relate to web UI 3080

The desktop debug ports (9222, 9229, 9230) are Electron debug channels, a different thing from the dsh web UI service port 3080, with different ranges that do not conflict when both run (source). Three points:

  1. Different purposes — debug ports connect developer tools, while 3080 serves the web UI to a browser. Expected: one for diagnosis, one for use.
  2. Different ranges — debug ports sit in 92xx and the web UI on 3080. Expected: they never take each other's port.
  3. Both can run — the two coexist. Expected: debugging the desktop app while the web UI is open is fine.
  4. Web UI is configured separately — for the access address and settings see How to use the dsh web UI.

Caveats and limits of DeepSeek Harness desktop debugging

  1. Do not leave debug ports open: they are a developer channel and should be closed for everyday use to avoid exposing local interfaces.
  2. Change ports on conflict: when 9222/9229/9230 are taken, export the variables to free ports before launch.
  3. Development mode targets source: pnpm run dev:desktop needs the repository and dependencies, while ordinary users just install the release.
  4. Confirm plugins are installed first: for a plugin problem, confirm it is installed in the desktop profiles/desktop, see Is desktop config separate.
  5. Do not delete the lock file: single-instance is guaranteed by profiles/desktop/lock, so after repeated debug launches and odd behavior, first confirm no stale process remains.

Sources: Desktop README (official repository)

FAQ

Which debug ports does the DeepSeek Harness desktop app have, and what does each map to?

The DeepSeek Harness desktop app has three debug port variables: DSH_DESKTOP_MAIN_INSPECT_PORT defaults to 9229 for the main process, DSH_DESKTOP_RENDERER_DEBUG_PORT defaults to 9222 for the renderer, and DSH_DESKTOP_HOST_INSPECT_PORT defaults to 9230 for the host process.

How do I open developer tools in the DeepSeek Harness desktop app?

The environment variable DSH_DESKTOP_OPEN_DEVTOOLS controls whether developer tools open automatically, so set it before launching the desktop app. To inspect manually, connect through the renderer debug port instead.

Will the DeepSeek Harness desktop debug ports conflict with the web UI port 3080?

No, they are two different things: the desktop debug ports default to 9222, 9229 and 9230 as Electron debug channels, while 3080 is the dsh web UI service port. Their ranges differ, so running both at once does not conflict.

How do I run the DeepSeek Harness desktop app in development mode?

Run pnpm run dev:desktop in the repository to start development mode, and combine it with the debug port variables to set breakpoints and inspect the interface. That command targets source development; ordinary use just needs the released build.

Related Terms

DSH_DESKTOP_MAIN_INSPECT_PORT
DSH_DESKTOP_MAIN_INSPECT_PORT is the debug port variable for the DeepSeek Harness desktop main process, defaulting to 9229, used to attach a main-process debugger.— DeepSeek Harness desktop README
DSH_DESKTOP_RENDERER_DEBUG_PORT
DSH_DESKTOP_RENDERER_DEBUG_PORT is the debug port variable for the DeepSeek Harness desktop renderer, defaulting to 9222, used for DevTools on the interface layer.— DeepSeek Harness desktop README
DSH_DESKTOP_HOST_INSPECT_PORT
DSH_DESKTOP_HOST_INSPECT_PORT is the debug port variable for the DeepSeek Harness desktop host process, defaulting to 9230, used to debug the process carrying host logic.— DeepSeek Harness desktop README
DevTools
DevTools is the developer tooling built into Electron, opened in the DeepSeek Harness desktop app through DSH_DESKTOP_OPEN_DEVTOOLS and the renderer debug port to view the console and network requests.— DeepSeek Harness desktop README

Sources