The variable in the .env file needs to start with REACT_APP_ for it to be picked up
REACT_APP_API_URL=http://localhost:3000
# With create react app, you need to prefix REACT_APP_ to the variable name. ex:
REACT_APP_SOME_API_KEY=some_api_key
REACT_APP_SOME_ENV_VAR=some_env_value