Codex CLI: /import Now Works in Remote Sessions

CodexView original changelog

Codex CLI 0.157.0 extended the /import command, previously limited to a local foreground terminal, to also work in remote sessions and local background-server sessions. The change is powered by a new automatic background-server startup capability that activates for eligible interactive sessions and offers recovery choices when server settings are incompatible. Together, these changes make it easier for developers running Codex outside a single local terminal, such as from a mobile device or a second machine, to still pull in prior context, settings, and sessions.

Key Takeaways

  • Codex CLI 0.157.0 makes /import available in remote and background-server sessions for the first time, not just local foreground terminals.
  • The change is powered by a new automatic background-server startup capability that activates for eligible interactive sessions without manual setup.
  • When server settings are incompatible, Codex now offers recovery choices instead of failing outright.
  • The update matters most for developers who run Codex sessions remotely, such as from a mobile device or a second machine, and want to bring in prior context.
  • Some users reported startup regressions tied to the new background-server behavior, including a Windows daemon-privilege error and a macOS compatibility issue with workspace_dependencies.
  • The feature extends Codex's existing /import command, which already migrates settings and sessions from tools like Cursor and Claude Code.

/import Reaches Remote and Background Sessions

Codex CLI's /import command, which lets developers migrate settings, MCP servers, plugins, sessions, and slash commands from tools like Cursor and Claude Code, previously only worked from a local, foreground terminal session. Codex CLI 0.157.0 removed that restriction, making /import available in remote sessions and in sessions running through Codex's local background-server as well.

Why the Restriction Existed

/import had been unavailable while a task was running, in remote sessions, and while connected to the local app-server daemon. That meant developers who started a Codex session from a phone or a secondary machine, or who were running a task in the background, could not bring in the same imported context and settings available to someone working directly in a local terminal.

Automatic Background-Server Startup

The change is underpinned by a new capability that enables automatic background-server startup for eligible interactive sessions, with recovery choices offered when server settings are incompatible. In practice, this means Codex can now stand up the background server it needs on its own, rather than requiring a developer to start it manually before remote or background features become available.

Who This Helps

The update matters most to developers who do not run Codex from a single, always-present local terminal: those coordinating Codex from a mobile app, running sessions in the background while doing other work, or connecting to a session remotely. For them, /import becoming available in these contexts closes a gap between what is possible locally and what is possible remotely.

Early Rough Edges

As with any change to how the background server starts, a handful of platform-specific issues surfaced quickly after release, including a Windows daemon-privilege error that prevented startup from a non-elevated terminal, and a macOS compatibility check failure when the workspace_dependencies setting was enabled. Developers who hit unexpected startup failures on 0.157.0 should watch for follow-up patch releases addressing these cases.