# Codex Pro Tip: Instantly Switch Multiple Accounts with Official Cache and CC Switch Tool
## Still Struggling with Switching Codex Accounts?
The traditional way to switch accounts in Codex requires you to **log out**, then go through the browser to **re-authorize and log in**, a time-consuming and cumbersome process. This video reveals a more efficient and convenient method for managing multiple accounts, officially supported by the application's design.
---
## The Core Principle: Understanding Codex's Configuration Files
All of Codex's login and configuration data is stored in the `. Codex` folder within your user directory. Two files are critical to this process:
1. **`auth. json`**: This file stores your authorization credentials (Token) , whether it's for an official account or a third-party API.
2. **`config. toml`**: This file saves detailed application settings, such as the default model, API parameters (in API mode) , and more.
The principle behind fast switching is to **cache these two files for each of your different accounts**. When you need to switch, you simply replace the files in the `. Codex` directory with the ones from your target account's cache.
---
## Manual Operation vs. Tool Automation
> While you can manually copy and paste these files to switch accounts, this method is still inconvenient and prone to errors. Therefore, we introduce a powerful utility to streamline this: **CC Switch**.
**CC Switch** is an account switching management tool that helps us perform the above process safely and efficiently.
### How to Configure Accounts with CC Switch?
1. **Adding an Official App Account**
* Create a new Codex profile in CC Switch.
* After logging into the official app, find the `auth. json` and `config. toml` files in your `. Codex` folder. Copy their **contents** and paste them into the corresponding fields in CC Switch.
* Save the profile to create an account "snapshot. "
2. **Adding a Third-Party API Account**
* Create another new profile, but this time, you'll fill in the details provided by your API vendor.
* **API Key**: Enter your key, which typically starts with `SK-`.
* **API Address**: Enter the API request URL (usually ending in `/v1`) .
* **Model Parameters**: Configure the `config. toml` section with specific parameters required by the provider, such as `model_provider`.
Once configured, you simply select the desired account in CC Switch and click "Activate" (remember to close the Codex application before switching) . The account switch happens in an instant.
---
## Safety First: Compliant Usage
The method described in this video is fundamentally a way to manage configuration files generated and recognized by the official client. This is a **safe and compliant** practice because it doesn't modify or crack any official processes; it merely simplifies the manual file replacement. Please note that when using such tools, you should avoid features that might violate the terms of service (e. g. , 2api) to ensure your account's security.
By mastering this technique, you can seamlessly switch between Codex accounts for different work scenarios and projects, becoming a true productivity power user.