---
title: How do I resolve a 'process.env.CI = true' error?
description: Information on resolving a 'process.env.CI = true' error.
url: "https://vercel.com/kb/guide/how-do-i-resolve-a-process-env-ci-true-error"
published: 2025-11-03
last_updated: 2026-07-16
authors: Sam Ko
install_vercel_plugin: npx plugins add vercel/vercel-plugin
---

The `Treating warnings as errors because process.env.CI = true.` error is a build error that can appear with [create-react-app](https://create-react-app.dev/) builds. In summary, React warnings are being treated as build errors. This article covers how you can bypass this build error.

## Why this Happens

When the "Automatically expose [System Environment Variables](https://vercel.com/docs/concepts/projects/environment-variables#system-environment-variables)" setting is checked in the project's [**Environment Variables**](https://vercel.com/docs/concepts/projects/environment-variables#declare-an-environment-variable) [settings](https://vercel.com/docs/concepts/projects/environment-variables#declare-an-environment-variable), the Environment Variable with the **Name** as `CI` and with the **Value** as `true` is exposed. This causes create-react-app to treat React warnings as build errors.

![Selecting to automatically expose System Environment Variables in your Vercel Project.](https://images.ctfassets.net/hjgychtc108g/AkKNHhZjGAIBXQsxsF9If/64679a464746256e9f92e2a48cca0201/system_environment_variables.jpeg)

## How to Resolve

If you wish to change these errors back to warnings, add an [Environment Variable](https://vercel.com/docs/concepts/projects/environment-variables) to the Environment Variables UI with the **Name** as `CI` and the **Value** as `false`. This will override the System Environment Variable. Once added, redeploy your project.

![Adding an Environment Variable with the Name as CI and the Value as false.](https://images.ctfassets.net/hjgychtc108g/6MWgFMjmmSOFApa6sp05O5/c2929adc8c4be75658e124ba5cbfd341/environment_variable.jpeg)