> ## Documentation Index
> Fetch the complete documentation index at: https://anaconda.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Managing Terms of Service on the command line

export const Comments = ({children}) => {
  return <div class="my-4 px-5 py-4 overflow-hidden rounded-2xl flex gap-3 border border-zinc-500/20 bg-zinc-50/50 dark:border-zinc-500/30 dark:bg-zinc-500/10" data-callout-type="comments">
      <div class="w-4">
        <svg width="14" height="14" viewBox="0 0 640 640" fill="currentColor" xmlns="http://www.w3.org/2000/svg" class="w-5 h-5" aria-label="Comments">
            <path d="M320 112C434.9 112 528 205.1 528 320C528 434.9 434.9 528 320 528C205.1 528 112 434.9 112 320C112 205.1 205.1 112 320 112zM320 576C461.4 576 576 461.4 576 320C576 178.6 461.4 64 320 64C178.6 64 64 178.6 64 320C64 461.4 178.6 576 320 576zM280 400C266.7 400 256 410.7 256 424C256 437.3 266.7 448 280 448L360 448C373.3 448 384 437.3 384 424C384 410.7 373.3 400 360 400L352 400L352 312C352 298.7 341.3 288 328 288L280 288C266.7 288 256 298.7 256 312C256 325.3 266.7 336 280 336L304 336L304 400L280 400zM320 256C337.7 256 352 241.7 352 224C352 206.3 337.7 192 320 192C302.3 192 288 206.3 288 224C288 241.7 302.3 256 320 256z" />
        </svg>
      </div>
      <div class="text-sm prose min-w-0 w-full">
        {children}
      </div>
    </div>;
};

<Warning>
  We are aware of an issue with the Anaconda Terms of Service acceptance being prompted for in some continuous integration (CI) environments and actively working on a resolution.

  For information on solutions, see the [Troubleshooting](#troubleshooting) section below.

  For status updates, see our [status page](https://anaconda.statuspage.io/).
</Warning>

In order to use Anaconda's [default channels](/getting-started/working-with-conda/reference/default-channels) to install and update packages, you must accept Anaconda's [Terms of Service](https://www.anaconda.com/legal) (TOS). Channels other than Anaconda's channels may require a TOS acceptance as well. Anaconda has built a plugin that makes viewing and accepting a channel's TOS more straightforward and transparent to anyone who prefers to use conda at the command line (`conda-anaconda-tos`).

`conda-anaconda-tos` augments the existing conda workflow by automatically prompting you to accept the TOS for a given channel when necessary. `conda-anaconda-tos` is triggered any time you run a conda command that interacts with channels (for example, using `conda create`, `conda search`, `conda install`, and so on), but is meant to be unobtrusive to your work. For more information on `conda-anaconda-tos`, see the plugin's [GitHub repository](https://github.com/anaconda/conda-anaconda-tos).

<Note>
  If you have an enterprise license agreement with Anaconda, that agreement governs your use of the applicable Anaconda products and supersedes any terms presented to your licensed users through the plugin during your subscription term.
</Note>

## Installing conda-anaconda-tos

<note>
  `conda-anaconda-tos` was added to Anaconda installers in:

  * Anaconda Distribution 2025.06-0
  * Miniconda 25.1-1-0
</note>

You can find `conda-anaconda-tos` in your `(base)` environment. If you're unsure if you have `conda-anaconda-tos` in your `(base)` environment, you can check by running the following command:

```sh theme={null}
conda list --name base conda-anaconda-tos
```

If necessary, install `conda-anaconda-tos` into your `(base)` environment by running the following command:

```sh theme={null}
conda install --name base conda-anaconda-tos
```

## An example user interaction

Let's assume you've recently installed the latest version of Miniconda and want to create an environment to install the package `pandas`. Your command might look like:

```sh theme={null}
conda create --name pandas-env pandas
```

With no additional configurations, conda searches the following channels by default:

* `https://repo.anaconda.com/pkgs/main`
* `https://repo.anaconda.com/pkgs/r`
* `https://repo.anaconda.com/pkgs/msys2`

`conda-anaconda-tos` gathers all of the channels in your `.condarc` file and reviews them to see if they require you to accept a TOS to use them. For each channel that requires a TOS, you will see:

```sh theme={null}
    Gathering channels...
    Reviewing channels...
    Do you accept the Terms of Service (ToS) for https://repo.anaconda.com/pkgs/main?
    [(a)ccept/(r)eject/(v)iew]:
```

* Enter `a` to accept the TOS.
* Enter `r` to reject the TOS.
* Enter `v` to display a link to a website that contains the TOS you're being asked to accept.

Whether you accept or reject a TOS, conda will ask you about the next channel, if any, that requires a TOS acceptance. Once you have accepted all required TOS, conda can be used as normal.

## Removing a channel with a rejected TOS

Rejecting a channel's TOS prevents conda from searching for, installing, or updating packages from that channel.

To prevent unnecessary errors from generating after you have rejected the TOS for a channel, remove it from your channels list:

```sh theme={null}
conda config --remove channels <CHANNEL>
```

<Comments>
  Replace \<CHANNEL> with the name/URL of your channel.
</Comments>

<Note>
  The recommended way to prevent conda from searching your default channels (`main`, `r`, `msys2`) is to remove the `defaults` channel entry with the following command:

  ```sh theme={null}
  conda config --remove channels defaults
  ```

  If `defaults` is the only channel in your `channels:` list, conda will error. Make sure that another channel is in your channels list if you plan to remove `defaults`.

  If necessary, you can add `defaults` back to your `channels:` list by running the following command:

  ```sh theme={null}
  conda config --add channels defaults
  ```

  This command can also be used to add any other channel to your `channels:` list.

  For more information on your `.condarc` file, see [Configuring channels](/getting-started/working-with-conda/channels#configuring-channels).
</Note>

## Using conda tos commands

While `conda-anaconda-tos` automatically prompts you when a channel's TOS needs an acceptance, the plugin also has its own set of commands for viewing and managing TOS for the channels listed in your `.condarc` and/or any other channels that you specify:

### Viewing all command options

View all possible command options:

```sh theme={null}
conda tos --help
```

### Displaying your TOS table

Display a table of your channels and any TOS required by them:

```sh theme={null}
conda tos
```

This command returns a table that displays:

* A list of all your channels. This includes `defaults` and the channels in your `channels:` list.
* For any channels that have a TOS, a timestamp for when each TOS was last updated (see **Version** column).
* The TOS acceptance status. If rejected, the column will display `rejected`. If accepted, the column will display a timestamp for when the acceptance occurred (see **Accepted** column).

<Note>
  If a channel's TOS is updated, its Version timestamp will also be updated. You will be asked to accept the TOS again the next time you use that channel and the Accepted timestamp for that TOS will also update in the table.
</Note>

### Managing TOS for all channels

By default, the `conda-anaconda-tos` plugin displays, accepts, and rejects the TOSes of *all* channels specified in the `defaults` and `channels:` lists in your `.condarc` file.

Display website URL links to view the text of all applicable TOS:

```sh theme={null}
conda tos view
```

Accept all TOS for all channels:

```sh theme={null}
conda tos accept
```

Reject all TOS for all channels:

```sh theme={null}
conda tos reject
```

### Managing TOS per channel

View, accept, or reject the TOS for a specific channel by running a variation of the following command:

```sh theme={null}
conda tos <COMMAND> --override-channels --channel <CHANNEL>
```

<Comments>
  Replace \<COMMAND> with a command option (view, accept, reject).<br />
  Replace \<CHANNEL> with the channel name/URL you want to specify.
</Comments>

## CI/CD Environments

In CI/CD environments (detected via `CI=true`), the plugin will automatically accept Terms of Service and print a warning message. This ensures automated builds don't get blocked waiting for user input.

### Docker in CI/CD Environments

When using Anaconda's Docker images in continuous integration systems, the `CI` environment variable might not be automatically passed to the container, which can lead to unexpected ToS prompts during your CI/CD workflows.

Anaconda recommends passing the `CONDA_PLUGINS_AUTO_ACCEPT_TOS` environment variable to Docker or explicitly accepting the ToS by running `conda tos accept`:

* Pass the `CONDA_PLUGINS_AUTO_ACCEPT_TOS` environment variable to Docker using the Docker CLI:

  ```bash theme={null}
  docker run \
    -e CONDA_PLUGINS_AUTO_ACCEPT_TOS=true \
    continuumio/anaconda3 \
    bash -c "conda install some-package"
  ```

* Explicitly accept ToS in your Docker command using the Docker CLI:

  ```bash theme={null}
  docker run \
    continuumio/anaconda3 \
    bash -c "conda tos accept && conda install some-package"
  ```

#### Docker Containers in GitHub Actions

Similarly, when using Docker containers in GitHub Actions, the `CI` environment variable will not be automatically passed.

* Pass the `CONDA_PLUGINS_AUTO_ACCEPT_TOS` environment variable to Docker:

  ```yaml highlight={6-7} theme={null}
  jobs:
    build:
      runs-on: ubuntu-latest
      container:
        image: continuumio/anaconda3
      env:
        CONDA_PLUGINS_AUTO_ACCEPT_TOS: true
      steps:
        - uses: actions/checkout@v3
        - name: Install Packages
          run: conda install ...
  ```

* Explicitly accept ToS in your Docker command:

  ```yaml highlight={8-9} theme={null}
  jobs:
    build:
      runs-on: ubuntu-latest
      container:
        image: continuumio/anaconda3
      steps:
        - uses: actions/checkout@v3
        - name: Accept ToS
          run: conda tos accept
        - name: Install Packages
          run: conda install ...
  ```

<Note>
  Service containers and composite actions in GitHub Actions also inherit the runner's environment, including the `CI` variable. However, manually invoked Docker commands within steps do not automatically inherit these variables.
</Note>

## Troubleshooting

### CI/CD workflows erroring

#### Problem

The `conda-anaconda-tos` plugin currently detects CI/CD environments by looking for `CI=true`, in order to automatically accept TOS and not cause the workflow to hang while waiting for user input.

CI systems that do not leverage the `CI=true` flag are currently experiencing errors because the plugin is waiting for user input to accept TOS. This issue is actively being worked on.

#### Solution

You can configure auto acceptance of TOS in the following ways:

* Configure ToS auto acceptance in your `.condarc` file:

  ```yaml theme={null}
  plugins:
    auto_accept_tos: true
  ```

* Use the command-line flag (conda >= 25.5.0):

  ```bash theme={null}
  conda config --set plugins.auto_accept_tos yes
  ```

* Set the environment variable:

  ```bash theme={null}
  export CONDA_PLUGINS_AUTO_ACCEPT_TOS=yes
  ```

For more information on accepting TOS in your Docker containers, see [CI/CD Environments](#ci/cd-environments) above.

### Being prompted to re-accept a TOS

#### Problem

There is a known issue with `conda-anaconda-tos` where you might be prompted to re-accept a TOS you have already accepted after updating conda. This happens because the plugin currently treats package updates the same as uninstalls for security reasons. If you update your conda environment with `conda update -n base --all`, the plugin clears your TOS acceptance record as a precaution and you will be prompted again to accept the TOS, when applicable.

#### Solution

Re-accept any TOS prompts you receive.

While we're working on a more refined approach to this issue, re-accepting any TOS prompts ensures you're always properly consented to use Anaconda's ToS-governed resources. This behavior will be improved in future releases.

<Note>
  If TOS acceptance prompts are appearing often or if you haven't updated conda and are receiving TOS acceptance prompts that you have already accepted, this might be an indication that your TOS acceptance record is corrupted.

  To solve this issue, you can either clear your cache and TOS acceptance records or fully uninstall and reinstall `conda-anaconda-tos`, which will also clear your TOS acceptance records.

  Open Anaconda Prompt (Terminal on macOS/Linux) and run one of the following commands:

  <CodeGroup>
    ```sh Clear cache theme={null}
    conda tos clean --all
    ```

    ```sh Uninstall/reinstall theme={null}
    conda install --name base --force-reinstall conda-anaconda-tos
    ```
  </CodeGroup>

  Re-accept any TOS prompts you encounter.
</Note>
