AI Assistant 2026.1 Help

Codex

Codex logo Codex is a third-party coding agent by OpenAI available for use in AI Assistant. It can help you to design and implement features, fix bugs, answer questions, review code, and assist with a wide range of development tasks.

Install Codex

Initially, Codex is not installed in AI Assistant. To install it:

  1. In the chat, click and select Codex logo Codex from the list.

    Install Claude Agent
  2. Type your prompt and press Enter. This will trigger the installation.

  3. Accept the terms of service by clicking Install and Continue.

    Accept the terms of service

Once installed, you can start using Codex.

The installed agent and corresponding configuration files are located at:

  • Windows: %LOCALAPPDATA%\JetBrains\<product><version>\aia\codex

  • macOS: ~/Library/Caches/JetBrains/<product><version>/aia/codex

  • Linux: ~/.cache/JetBrains/<product><version>/aia/codex

Authenticate with a ChatGPT account

If you want to use Codex with your existing ChatGPT account, you can authenticate through OAuth:

  1. Navigate to Settings | Tools | AI Assistant | Providers & API keys.

    Providers & API keys settings
  2. In the Account section, click Sign in with ChatGPT Account. You will be redirected to AI Chat to continue the activation process.

  3. Click Log in via ChatGPT account to open the OpenAI sign-in page.

    Log in via ChatGPT account
  4. Authenticate with your ChatGPT account.

Once authentication is complete, you can start using Codex with your ChatGPT account.

Log out of ChatGPT account

To log out of your ChatGPT account:

  1. Navigate to Settings | Tools | AI Assistant | Providers & API keys.

  2. In the Accounts section, click Log out.

    Log out of your ChatGPT account

Use Codex with an OpenAI API token

Instead of authenticating through OAuth, you can also provide your OpenAI API token in the settings and use Codex with it:

  1. Navigate to Settings | Tools | AI Assistant | Providers & API keys.

    AI Assistant Models & API keys settings
  2. In the Third-party AI providers section, select OpenAI as a Provider.

  3. Enter your token in the API Key field and click Test Connection to verify that the connection is established.

  4. Click OK to apply changes.

After completing these steps, you can start using Codex with the configured OpenAI API key.

Select operation mode

Codex has several operation modes that you can use:

  • Read-only – Codex can browse and explain the codebase but cannot modify files or run commands.

  • Agent – Codex can modify files within the project workspace but cannot make changes outside the project without approval.

  • Agent (full access) – Codex can modify files anywhere on the machine and run commands with minimal restrictions, enabling system-level edits, installs, and full workflows.

To switch between modes, use the mode picker dropdown in the prompt window.

Mode picker

Select processing model

To select a model that Codex uses to process your requests, click and select the model from the list.

Select the model

You can also select the Reasoning level for the model. Model reasoning refers to a model's ability to perform multi-step analysis and solve complex tasks. The selected level controls how much analytical processing the model applies when generating responses.

Approve operations

In the Read-only mode, Codex requests your permission to run suggested bash commands, perform file operations, or use external tools. In this case, you can either approve or skip the operation.

Codex requests an approve
  • Allow Once – allows Codex to execute the command this time only. You will be asked again if the command is requested later.

  • Allow for Session – allows Codex to execute this command for the current session without asking again.

  • Reject – prevents Codex from executing this command.

Rollback operations

If the changes introduced by Codex do not suit you, you can roll them back. To do this:

  1. Navigate to the pane listing the changed files.

  2. Do one of the following:

    • To roll back changes in a specific file, hover over it and click .

      Rollback changes in a specific file
    • To roll back changes in all files, click Rollback.

      Rollback changes in all files

You can also roll back to a checkpoint, restoring your project to an earlier point in the conversation to undo changes or retry with different instructions. To do this:

  1. Navigate to the prompt you want to roll back to.

  2. Hover over it and click Rollback here.

  3. Confirm the operation by clicking Rollback.

    Rollback changes

    This reverts all changes made by Codex, as well as any manual changes you made after the selected point.

View Codex status and configuration

Codex provides informational / commands to view the current agent configuration and manage the active session:

  • /mcp – provides the list of configured MCP servers.

  • /skills – provides the list of available skills. For more information about skills, refer to Use Codex skills.

  • /logout – ends the current session and logs out of the ChatGPT account.

  • /status – displays information about the current session, including token usage and the available context window.

Use Codex skills

Skills give Codex additional capabilities to handle specific tasks and structured workflows. Each skill consists of instructions, supporting resources, and scripts that define how the agent performs the task.

You can add skills in two ways:

  • Install curated skills from public repositories, such as openai/skills. They can be installed by invoking the $skill-installer skill, which adds them to the Codex environment.

  • Create custom skills by using the $$skill -creator skill and describing the required functionality.

Once installed or created, skills can be invoked:

  • Automatically, when a skill is relevant to the task you describe.

  • Explicitly, by referencing a specific skill with the $ prefix in your prompt.

To view the skills currently available to Codex, use the /skills command.

Use database-specific tools with Codex

Currently, Codex requires the following configuration to work with database-specific tools:

  1. In Settings | Tools | MCP Server, select the Enable MCP Server checkbox, confirm your action in the Enable MCP Server? dialog, then click Apply.

  2. Click Copy HTTP Stream Config.

  3. In Settings | Tools | AI Assistant | Model Context Protocol (MCP), click Add.

  4. In the New MCP Server dialog that opens, open the HTTP tab and paste the copied value as idea-http server.

    The resulting JSON configuration is as follows:

    { "mcpServers": { "idea-http": { "type": "streamable-http", "url": "http://127.0.0.1:64344/stream", "headers": {} } } }

    The port number may vary. Make sure it matches the port configured for the server and shown in Tools | MCP Server in the Enable MCP Server setting.

  5. Click Apply to save the configuration and close the New MCP Server dialog.

  6. On the MCP Server page of the Settings dialog, click Auto-Configure under Codex to apply the new configuration.

  7. Click OK to save the MCP server.

Uninstall Codex

If you want to uninstall Codex and clean up the agent configuration, do the following:

  1. Press Shift twice to open the Search Everywhere window.

  2. Start typing Clean Up Codex Installation, and select the suggestion.

    Clean Up Codex Installation action

As a result, Codex is removed, and its configuration files are cleaned up.

Alternatively, you can manually delete the codex folder located in the IDE system directory under aia/codex:

  • Windows: %LOCALAPPDATA%\JetBrains\<product><version>\aia\codex

  • macOS: ~/Library/Caches/JetBrains/<product><version>/aia/codex

  • Linux: ~/.cache/JetBrains/<product><version>/aia/codex

24 March 2026