Troubleshooting

Atlas TUI error: Failed to copy to clipboard

Updated 7 min read

Atlas shows Failed to copy to clipboard, Failed to copy URL to clipboard, or Failed to copy session transcript because the Atlas TUI shells out to a platform clipboard command and the command exited non-zero, rejecting with <command> exited with code <n>. Install the platform clipboard tool your environment needs, for example xclip or wl-copy on Linux, and make sure it is on PATH for the process running the TUI, not just your login shell. Over SSH or in a container there is usually no clipboard at all, so export the transcript to a file instead.

Why does the Atlas TUI say Failed to copy to clipboard

The Atlas TUI says Failed to copy to clipboard because it shells out to a platform clipboard command and rejects the promise when that command exits non-zero. The underlying rejection reads <command> exited with code <n>, and in 2026 the session commands still catch it and show an error toast instead of crashing.

Atlas does not implement clipboard access itself. Copying text, a URL, or a session transcript means running the clipboard binary your platform provides and handing it the data on stdin. When that binary is missing, unusable, or has nothing to talk to, it exits non-zero and Atlas reports the failure honestly. The three toasts, Failed to copy to clipboard, Failed to copy URL to clipboard, and Failed to copy session transcript, all trace to the same helper and the same rejection, so the fix is identical for all three.

How to install a clipboard tool for Atlas on Linux

Install the platform clipboard tool your environment needs, for example 1 of xclip or wl-copy on Linux. Atlas shells out to that command, so on a headless or minimal Linux install where neither is present, every clipboard action in the Atlas TUI rejects with <command> exited with code <n>.

Which binary you need depends on your display server. X11 sessions use xclip. Wayland sessions use wl-copy. Installing the wrong one for your session still leaves the command failing, because the tool cannot reach a display server it was not built for. After installing, confirm the binary runs from a plain shell before retrying in Atlas: if the clipboard tool itself errors when you run it by hand, Atlas will surface exactly that failure as Failed to copy to clipboard.

Why the clipboard command works in my shell but not in Atlas

A clipboard command that works in your shell but fails in Atlas is almost always 1 problem: PATH. Check that the clipboard command is on PATH for the process running the TUI, not just your login shell, because a binary reachable only through your interactive profile is invisible to a process that never sourced it.

The Atlas TUI is a terminal-native TUI rendered with SolidJS through the OpenTUI renderer, and the process it runs in inherits whatever environment launched it. If you start Atlas from a desktop launcher, a service manager, or a wrapper script, the PATH it sees may be much shorter than the one your interactive shell builds up. Verify by checking the PATH the Atlas process actually has rather than the one you see when you type in the terminal, and install the clipboard tool somewhere that PATH already covers.

How to copy an Atlas transcript over SSH or in a container

Over SSH or in a container there is usually no clipboard at all, so the Atlas toast Failed to copy session transcript is expected rather than broken. Export the transcript to a file instead. The export command is the 1 fallback that works here, because it writes the transcript rather than copying it.

A remote shell has no access to your local machine's clipboard, and a container typically has no display server and no clipboard tool inside it. Installing xclip inside a container will not help, because there is nothing for it to talk to. Exporting the transcript to a file is the correct answer in these environments: the file lands on the remote or container filesystem, and you retrieve it the same way you retrieve any other file from that machine. Some terminal emulators offer their own copy path, but that is outside what Atlas controls.

How to verify the clipboard fix worked

Verify the Atlas clipboard fix by copying again and confirming no toast appears. The Atlas session commands show their 3 failure toasts, Failed to copy to clipboard, Failed to copy URL to clipboard, and Failed to copy session transcript, only when the platform clipboard command rejects, so a silent copy means it exited 0.

Confirm at both layers. Run the clipboard binary directly, for example piping text into xclip or wl-copy, and check that it exits zero and that pasting elsewhere produces the text. Then retry the copy inside the Atlas TUI. If the direct run works but Atlas still fails, the remaining difference is PATH for the process running the TUI. If neither works, the environment has no usable clipboard and the export command is the right fallback.

How to fix it

  1. 01Install the platform clipboard tool your environment needs, for example xclip or wl-copy on Linux, so the command the Atlas TUI shells out to actually exists.
  2. 02Check that the clipboard command is on PATH for the process running the TUI, not just your login shell. A binary your interactive shell can find is not automatically visible to Atlas.
  3. 03Over SSH or in a container, accept that there is usually no clipboard at all, and export the transcript to a file instead of copying it.
  4. 04Use the export command as a fallback: it writes the transcript rather than copying it, so it works in environments with no clipboard.
  5. 05Retry the copy in the Atlas TUI and confirm no Failed to copy to clipboard toast appears.

Frequently asked questions

Why does Atlas say Failed to copy to clipboard?
The Atlas TUI shells out to a platform clipboard command and rejects when that command exits non-zero, with the underlying error <command> exited with code <n>. Usually the clipboard binary is missing or not on PATH.
What clipboard tool do I need for Atlas on Linux?
Install the platform clipboard tool your environment needs, for example xclip or wl-copy on Linux. X11 sessions use xclip and Wayland sessions use wl-copy, and installing the wrong one for your session still fails.
How do I copy an Atlas session transcript over SSH?
Over SSH there is usually no clipboard at all. Use the export command as a fallback: it writes the transcript to a file rather than copying it, then retrieve the file from the remote machine.
xclip works in my terminal but Atlas still fails to copy. Why?
Check that the clipboard command is on PATH for the process running the TUI, not just your login shell. A process launched outside your interactive shell may have a much shorter PATH.
Does Failed to copy URL to clipboard mean Atlas crashed?
No. The Atlas session commands catch the clipboard rejection and show an error toast instead of crashing. The TUI keeps running and nothing in your session is lost.
Can I use the clipboard from Atlas inside a Docker container?
Usually not. A container typically has no clipboard at all, so installing a clipboard tool inside it does not help. Export the transcript to a file instead of copying it.
What does <command> exited with code <n> mean in Atlas?
It is the rejection from the platform clipboard command Atlas shelled out to. Atlas reports the command's own non-zero exit, then the session commands turn it into a Failed to copy to clipboard toast.

Try Atlas in your terminal

The terminal-native AI coding agent. Free core, single binary.

Install Atlas

Related guides

Atlas with Gemma 3 12B (Ollama): 128K Context and Screenshots in 2026

Gemma 3 12B (Ollama) gives Atlas a 128K tokens (131,072) window and multimodal image input from an 8.1GB download, Free (self-hosted). Setup, sizing, and limits.

Atlas with Groq (gateway) in 2026: LPU Speed for the Agent Loop

Groq (gateway) runs open models on LPU hardware for Atlas: GPT-OSS 120B at $0.15 / $0.60 per Mtok, 131K tokens (131,072) context, and no Claude or GPT-5.

Atlas for Actix Web in 2026

Atlas is a terminal-native AI coding agent for Actix Web in 2026. It reads extractors and app_data, then runs cargo test and cargo clippy behind a prompt.

Atlas with DeepSeek Coder 6.7B (Ollama): the thin-hardware fallback in 2026

DeepSeek Coder 6.7B (Ollama) in Atlas: a 3.8GB pull, roughly 6GB to serve, 16K tokens (16,384) of context, Free (self-hosted). Dated, but it starts fast.

Atlas for Expo: Terminal-Native AI Coding for expo-router and Config Plugins in 2026

Atlas is a terminal-native AI coding agent for Expo apps in 2026, covering expo-router file routes, config plugins, and EAS build profiles with diff-first review.

Upgrade a Dependency and Fix the Breakage with Atlas (2026 Workflow)

How to upgrade a dependency and fix the breakage with Atlas in 2026: bash drives the package manager, webfetch pulls the release notes, edit fixes each compiler error.

Atlas vs Trae: AI Coding Agents in 2026

Atlas and Trae offer distinct AI coding agent experiences in 2026. Atlas provides terminal-native control and local data privacy, while Trae offers a full IDE with SOLO Builder and cloud tasks.

Atlas with GPT-5.6 Luna: Best Price Per Context in 2026

GPT-5.6 Luna keeps the full 1,050,000 token window at $1 / $6 per Mtok, one fifth of GPT-5.6. The best price-per-context ratio for agentic coding in Atlas in 2026.

Browse this resource hub