---
title: System environment variables
description: Learn about system variables used by Turborepo.
---

import { Heading } from 'fumadocs-ui/components/heading';

By setting certain environment variables, you can change Turborepo's behavior. This can be useful for creating specific configurations for different environments and machines.

System environment variables are always overridden by flag values provided directly to your `turbo` commands.

<table id="system-environment-variables-table">
  <thead>
    <tr>
      <th>Variable</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr id="force_color">
      <td>
        <code>FORCE_COLOR</code>
      </td>
      <td>Forces color to be shown in terminal logs</td>
    </tr>
    <tr id="turbo_api">
      <td>
        <code>TURBO_API</code>
      </td>
      <td>
        Set the base URL for{' '}
        <a href="/docs/core-concepts/remote-caching">Remote Cache</a>.
      </td>
    </tr>
    <tr id="turbo_binary_path">
      <td>
        <code>
          <code>TURBO_BINARY_PATH</code>
        </code>
      </td>
      <td>
        Manually set the path to the <code>turbo</code> binary. By default,{' '}
        <code>turbo</code> will automatically discover the binary so you should
        only use this in rare circumstances.
      </td>
    </tr>
    <tr id="turbo_cache">
      <td>
        <code>
          <code>TURBO_CACHE</code>
        </code>
      </td>
      <td>
        Control reading and writing for cache sources. Uses the same syntax as{' '}
        <a href="/docs/reference/run#--cache-options">
          {' '}
          <code>--cache</code>
        </a>
        .
      </td>
    </tr>
    <tr id="turbo_cache_dir">
      <td>
        <code>TURBO_CACHE_DIR</code>
      </td>
      <td>
        Sets the cache directory, similar to using{' '}
        <a href="/docs/reference/run#--cache-dir-path">
          {' '}
          <code>--cache-dir</code>
        </a>{' '}
        flag.
      </td>
    </tr>
    <tr id="turbo_ci_vendor_env_key">
      <td>
        <code>TURBO_CI_VENDOR_ENV_KEY</code>
      </td>
      <td>
        Set a prefix for environment variables that you want
        <strong>excluded</strong> from <a href="/docs/crafting-your-repository/using-environment-variables#framework-inference">
          Framework Inference
        </a>.<span></span>
        <strong>NOTE</strong>: This does not need to be set by the user and should
        be configured automatically by supported platforms.
      </td>
    </tr>
    <tr id="turbo_dangerously_disable_package_manager_check">
      <td>
        <code>TURBO_DANGEROUSLY_DISABLE_PACKAGE_MANAGER_CHECK</code>
      </td>
      <td>
        Disable checking the <code>packageManager</code> field in{' '}
        <code>package.json</code>. You may run into{' '}
        <a href="/docs/reference/run#--dangerously-disable-package-manager-check">
          errors and unexpected caching behavior
        </a>{' '}
        when disabling this check. Use <code>true</code> or <code>1</code> to
        disable.
      </td>
    </tr>
    <tr id="turbo_download_local_enabled">
      <td>
        <code>TURBO_DOWNLOAD_LOCAL_ENABLED</code>
      </td>
      <td>
        Enables global <code>turbo</code> to install the correct local version
        if one is not found.
      </td>
    </tr>
    <tr id="turbo_force">
      <td>
        <code>TURBO_FORCE</code>
      </td>
      <td>
        Set to <code>true</code> to force all tasks to run in full, opting out
        of all caching.
      </td>
    </tr>
    <tr id="turbo_global_warning_disabled">
      <td>
        <code>TURBO_GLOBAL_WARNING_DISABLED</code>
      </td>
      <td>
        Disable warning when global <code>turbo</code> cannot find a local
        version to use.
      </td>
    </tr>
    <tr id="turbo_print_version_disabled">
      <td>
        <code>TURBO_PRINT_VERSION_DISABLED</code>
      </td>
      <td>
        Disable printing the version of <code>turbo</code> that is being
        executed.
      </td>
    </tr>
    <tr id="turbo_log_order">
      <td>
        <code>TURBO_LOG_ORDER</code>
      </td>
      <td>
        Set the <a href="/docs/reference/run#--log-order-option">log order</a>.
        Allowed values are <code>grouped</code> and <code>default</code>.
      </td>
    </tr>
    <tr id="turbo_login">
      <td>
        <code>TURBO_LOGIN</code>
      </td>
      <td>
        Set the URL used to log in to{' '}
        <a href="/docs/core-concepts/remote-caching">Remote Cache</a>. Only
        needed for self-hosted Remote Caches that implement an endpoint that
        dynamically creates tokens.
      </td>
    </tr>
    <tr id="turbo_no_update_notifier">
      <td>
        <code>TURBO_NO_UPDATE_NOTIFIER</code>
      </td>
      <td>
        Remove the update notifier that appears when a new version of{' '}
        <code>turbo</code> is available. You can also use{' '}
        <code>NO_UPDATE_NOTIFIER</code> per ecosystem convention.
      </td>
    </tr>
    <tr id="turbo_platform_env">
      <td>
        <code>TURBO_PLATFORM_ENV</code>
      </td>
      <td>
        A CSV of environment variable keys that are configured in a supported CI
        environment (Vercel). <strong>NOTE</strong>: This variable is meant for
        platforms looking to implement zero-configuration environment variables.
        You are not meant to use this variable as an end user.{' '}
      </td>
    </tr>
    <tr id="turbo_platform_env_disabled">
      <td>
        <code>TURBO_PLATFORM_ENV_DISABLED</code>
      </td>
      <td>
        Disable checking environment variables configured in your{' '}
        <code>turbo.json</code> against those set on your supported platform
      </td>
    </tr>
    <tr id="turbo_preflight">
      <td>
        <code>TURBO_PREFLIGHT</code>
      </td>
      <td>
        Enables sending a preflight request before every cache artifact and
        analytics request. The follow-up upload and download will follow
        redirects. Only applicable when{' '}
        <a href="/docs/core-concepts/remote-caching">Remote Caching</a> is
        configured.
      </td>
    </tr>
    <tr id="turbo_remote_cache_read_only">
      <td>
        <code>TURBO_REMOTE_CACHE_READ_ONLY</code>
      </td>
      <td>
        Prevent writing to the{' '}
        <a href="/docs/core-concepts/remote-caching">Remote Cache</a> - but
        still allow reading.
      </td>
    </tr>
    <tr id="turbo_remote_cache_signature_key">
      <td>
        <code>TURBO_REMOTE_CACHE_SIGNATURE_KEY</code>
      </td>
      <td>
        Sign artifacts with a secret key. For more information, visit{' '}
        <a href="/docs/core-concepts/remote-caching#artifact-integrity-and-authenticity-verification">
          the Artifact Integrity section
        </a>
        .
      </td>
    </tr>
    <tr id="turbo_remote_cache_timeout">
      <td>
        <code>TURBO_REMOTE_CACHE_TIMEOUT</code>
      </td>
      <td>
        Set a timeout in seconds for <code>turbo</code> to get artifacts from{' '}
        <a href="/docs/core-concepts/remote-caching">Remote Cache</a>.
      </td>
    </tr>
    <tr id="turbo_remote_cache_upload_timeout">
      <td>
        <code>TURBO_REMOTE_CACHE_UPLOAD_TIMEOUT</code>
      </td>
      <td>
        Set a timeout in seconds for <code>turbo</code> to upload artifacts to{' '}
        <a href="/docs/core-concepts/remote-caching">Remote Cache</a>.
      </td>
    </tr>
    <tr id="turbo_remote_only">
      <td>
        <code>TURBO_REMOTE_ONLY</code>
      </td>
      <td>Always ignore the local filesystem cache for all tasks.</td>
    </tr>
    <tr id="turbo_run_summary">
      <td>
        <code>TURBO_RUN_SUMMARY</code>
      </td>
      <td>
        Generate a <a href="/docs/reference/run#--summarize">Run Summary</a>{' '}
        when you run tasks.
      </td>
    </tr>
    <tr id="turbo_scm_base">
      <td>
        <code>TURBO_SCM_BASE</code>
      </td>
      <td>
        Base used by <code>--affected</code> when calculating what has changed
        from <code>base...head</code>
      </td>
    </tr>
    <tr id="turbo_scm_head">
      <td>
        <code>TURBO_SCM_HEAD</code>
      </td>
      <td>
        Head used by <code>--affected</code> when calculating what has changed
        from <code>base...head</code>
      </td>
    </tr>
    <tr id="turbo_team">
      <td>
        <code>TURBO_TEAM</code>
      </td>
      <td>
        The account name associated with your repository. When using{' '}
        <a
          href="https://vercel.com/docs/monorepos/remote-caching#vercel-remote-cache"
          rel="noreferrer noopener"
          target="_blank"
        >
          Vercel Remote Cache
        </a>
        , this is [your team's slug](https://vercel.com/d?to=%2F%5Bteam%5D%2F%7E%2Fsettings&title=Get+team+slug).
      </td>
    </tr>
    <tr id="turbo_teamid">
      <td>
        <code>TURBO_TEAMID</code>
      </td>
      <td>
        The account identifier associated with your repository. When using{' '}
        <a
          href="https://vercel.com/docs/monorepos/remote-caching#vercel-remote-cache"
          rel="noreferrer noopener"
          target="_blank"
        >
          Vercel Remote Cache
        </a>
        , this is your team's ID.
      </td>
    </tr>
    <tr id="turbo_telemetry_message_disabled">
      <td>
        <code>TURBO_TELEMETRY_MESSAGE_DISABLED</code>
      </td>
      <td>
        Disable the message notifying you that{' '}
        <a href="/docs/telemetry">Telemetry</a> is enabled.
      </td>
    </tr>
    <tr id="turbo_token">
      <td>
        <code>TURBO_TOKEN</code>
      </td>
      <td>
        The Bearer token for authentication to access{' '}
        <a href="/docs/core-concepts/remote-caching">Remote Cache</a>.
      </td>
    </tr>
    <tr id="turbo_ui">
      <td>
        <code>TURBO_UI</code>
      </td>
      <td>
        Enables TUI when passed true or 1, disables when passed false or 0.
      </td>
    </tr>
    <tr id="turbo_concurrency">
      <td>
        <code>TURBO_CONCURRENCY</code>
      </td>
      <td>
        Controls{' '}
        <a href="/repo/docs/reference/run#--concurrency-number--percentage">
          concurrency
        </a>{' '}
        settings in run or watch mode.
      </td>
    </tr>
    <tr id="turbo_sso_login_callback_port">
      <td>
        <code>TURBO_SSO_LOGIN_CALLBACK_PORT</code>
      </td>
      <td>
        Override the default port (9789) used for the SSO login callback server
        during authentication.
      </td>
    </tr>
  </tbody>
</table>

## Environment variables in tasks

Turborepo will make the following environment variables available within your tasks while they are executing:

| Variable       | Description                                                                                                                                          |
| -------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- |
| `TURBO_HASH`   | The hash of the currently running task.                                                                                                              |
| `TURBO_IS_TUI` | When using the [TUI](/docs/reference/configuration#ui), this variable is set to `true`.                                                              |
| `TURBO_IS_MFE` | When using the [microfrontends](/docs/guides/microfrontends), this variable is set to the port defined in `microfrontends.json` for the application. |
