Complete Guide to Continue Dev Environment Variables: Configuration, API Keys, and CLI Settings
Continue Dev supports over 30 environment variables that control API authentication, CLI output limits, network proxies, telemetry, and feature flags without modifying config files.
The continuedev/continue repository uses environment variables as the primary mechanism for runtime configuration across its CLI, VS Code extension, and core SDK. Whether you are providing LLM provider credentials in CI, limiting output lengths for automation, or routing traffic through corporate proxies, these variables allow you to customize behavior without touching the codebase.
LLM Provider API Keys
Continue reads standard API keys for major model providers directly from the environment. These are typically checked in the OpenAI adapters test suite and core SDK initialization.
OPENAI_API_KEY– Authenticates requests to OpenAI models. Referenced inpackages/openai-adapters/src/test/vercel-sdk.test.ts.ANTHROPIC_API_KEY– Required for Claude model access. Found inpackages/openai-adapters/src/test/vercel-sdk.test.ts.GEMINI_API_KEY– Google Gemini authentication. Defined inpackages/openai-adapters/src/test/main.test.ts.MISTRAL_API_KEY– For Mistral AI models. Located inpackages/openai-adapters/src/test/main.test.ts.VOYAGE_API_KEY– Voyage AI embedding models. Source:packages/openai-adapters/src/test/main.test.ts.AZURE_OPENAI_GPT41_API_KEY– Specific to Azure OpenAI GPT-4.1 deployments. Found inpackages/openai-adapters/src/test/main.test.ts.RELACE_API_KEYandINCEPTION_API_KEY– Experimental provider keys accessed inpackages/openai-adapters/src/test/main.test.ts.
Set these in your shell or CI environment before running Continue:
export OPENAI_API_KEY="sk-..."
export ANTHROPIC_API_KEY="sk-ant-..."
export GEMINI_API_KEY="..."
Continue-Specific Configuration
The SDK and CLI expose dedicated variables for Continue's proxy service and global directory management.
CONTINUE_API_KEY– Primary key for the Continue proxy service, validated inpackages/continue-sdk/typescript/tests/continue.test.ts.CONTINUE_GLOBAL_DIR– Overrides the default~/.continuedirectory for configuration and indexing. Useful for CI or isolated testing environments. Implemented inextensions/cli/vitest.global-dir-setup.ts.CONTINUE_USE_AI_SDK– Forces the SDK to use the new AI-SDK layer when set. Checked inpackages/openai-adapters/src/index.ts.CONTINUE_PROJECT_DIR– Exported to child processes pointing to the current workspace root. Found inextensions/cli/src/hooks/hookRunner.ts.CLAUDE_PROJECT_DIR– MirrorsCONTINUE_PROJECT_DIRfor Claude-specific tooling integrations.
Example for CI isolation:
export CONTINUE_GLOBAL_DIR="/tmp/continue-ci"
export CONTINUE_API_KEY="proxy-key-123"
CLI Output and Execution Limits
When running the Continue CLI in automated environments, you can enforce strict limits on tool outputs to prevent token overflow or excessive logging.
CONTINUE_CLI_FETCH_MAX_OUTPUT_LENGTH– Caps data returned from fetch commands. Source:extensions/cli/src/tools/fetch.ts.CONTINUE_CLI_BASH_MAX_OUTPUT_CHARSandCONTINUE_CLI_BASH_MAX_OUTPUT_LINES– Restrict bash command output. Implemented inextensions/cli/src/tools/runTerminalCommand.ts.CONTINUE_CLI_READ_FILE_MAX_OUTPUT_CHARSandCONTINUE_CLI_READ_FILE_MAX_OUTPUT_LINES– Limit file reading operations. Found inextensions/cli/src/tools/readFile.ts.CONTINUE_CLI_SEARCH_CODE_MAX_RESULTSandCONTINUE_CLI_SEARCH_CODE_MAX_RESULT_CHARS– Bound search results. Source:extensions/cli/src/tools/searchCode.ts.CONTINUE_CLI_DIFF_MAX_OUTPUT_LENGTH– Truncates diff command output. Located inextensions/cli/src/tools/viewDiff.ts.
Usage in automation scripts:
CONTINUE_CLI_FETCH_MAX_OUTPUT_LENGTH=5000 \
CONTINUE_CLI_BASH_MAX_OUTPUT_LINES=100 \
CONTINUE_CLI_SEARCH_CODE_MAX_RESULTS=10 \
continue run analysis.ts
Network Proxy and Certificate Configuration
For corporate environments or debugging, Continue respects standard proxy variables and custom certificate bundles.
HTTPS_PROXY,https_proxy,HTTP_PROXY,http_proxy– Proxy configuration for outbound HTTP(S) calls. Parsed inpackages/fetch/src/util.ts.NO_PROXY,no_proxy– Hosts that bypass the proxy. Checked inpackages/fetch/src/util.ts.NODE_EXTRA_CA_CERTS– Path to custom CA bundles for SSL validation. Used inpackages/fetch/src/certs.ts.VERBOSE_FETCH– Enables detailed HTTP request logging for debugging. Implemented inpackages/fetch/src/fetch.ts.FEATURE_FLAG_DISABLE_CUSTOM_FETCH– Disables the custom fetch wrapper when set. Found inpackages/openai-adapters/src/util.ts.
Debug network issues:
export VERBOSE_FETCH=1
export HTTPS_PROXY="http://proxy.company.com:8080"
export NODE_EXTRA_CA_CERTS="/etc/ssl/certs/ca-bundle.pem"
continue chat "Debug this API call"
Telemetry and Privacy Controls
Continue provides granular control over data collection and user identification.
CONTINUE_CLI_ENABLE_TELEMETRY– Set to0to disable CLI telemetry; any other value enables it (default enabled). Source:extensions/cli/src/telemetry/telemetryService.ts.CONTINUE_ALLOW_ANONYMOUS_TELEMETRY– Legacy flag for anonymous telemetry control. Found inextensions/cli/vitest.setup.ts.CONTINUE_METRICS_ENABLED–"0"disables all metric collection,"1"enables it. Overrides other telemetry flags when set. Located inextensions/cli/src/telemetry/telemetryService.ts.CONTINUE_USER_ID– Manually assigns a persistent user identifier instead of deriving it from the machine. Implemented inextensions/cli/src/util/uniqueId.ts.
Disable tracking completely:
CONTINUE_CLI_ENABLE_TELEMETRY=0 \
CONTINUE_ALLOW_ANONYMOUS_TELEMETRY=0 \
CONTINUE_METRICS_ENABLED=0 \
continue chat "Hello"
Testing and Development Flags
Internal and testing environments use specific flags to alter behavior.
CONTINUE_CLI_TEST– Puts the CLI into test mode, disabling interactive prompts and side effects. Checked inextensions/cli/src/util/stdin.ts.CONTINUE_REMOTE– Signals remote execution (e.g., CI), disabling certain interactive behaviors. Found inextensions/cli/src/util/git.ts.CONTINUE_CLI_AUTO_UPDATED– Prevents repeated auto-updates in the same session. Source:extensions/cli/src/services/UpdateService.ts.CONTINUE_E2E_NON_NEXT_EDIT_TEST– Toggles special test modes for VS Code end-to-end suites. Located inextensions/vscode/src/extension/VsCodeExtension.ts.IGNORE_API_KEY_TESTS– Skips tests requiring live API keys when set to"true". Found inpackages/openai-adapters/src/test/main.test.ts.IS_BINARY– Internal flag indicating the process runs as a packaged binary. Used inpackages/fetch/src/certs.ts.
CI testing configuration:
CONTINUE_CLI_TEST=1 \
CONTINUE_REMOTE=1 \
IGNORE_API_KEY_TESTS=true \
npm test
Feature Flags and Provider Selection
Toggle specific functionality without code changes.
CONTINUE_USE_BEDROCK– When set to"1", automatically selects AWS Bedrock during onboarding. Implemented inextensions/cli/src/onboarding.ts.CONTINUE_CLI_DISABLE_COMMIT_SIGNATURE– Skips GPG signing for commits when set. Found inextensions/cli/src/systemMessage.ts.
Force Bedrock selection:
export CONTINUE_USE_BEDROCK=1
continue chat "Generate Terraform for AWS"
Summary
- API Authentication: Set
OPENAI_API_KEY,ANTHROPIC_API_KEY,GEMINI_API_KEY, and provider-specific keys to authenticate LLM requests without hardcoding credentials. - Output Control: Use
CONTINUE_CLI_*_MAX_*variables to limit fetch, bash, file read, and search output lengths in automation. - Network Configuration: Configure
HTTPS_PROXY,NODE_EXTRA_CA_CERTS, andVERBOSE_FETCHfor corporate proxies and debugging. - Privacy: Disable telemetry with
CONTINUE_CLI_ENABLE_TELEMETRY=0andCONTINUE_METRICS_ENABLED=0. - Testing: Enable
CONTINUE_CLI_TESTandCONTINUE_REMOTEfor CI environments to suppress interactive prompts.
Frequently Asked Questions
What is the difference between CONTINUE_API_KEY and OPENAI_API_KEY?
OPENAI_API_KEY authenticates directly with OpenAI's API, while CONTINUE_API_KEY is used specifically for the Continue proxy service as implemented in packages/continue-sdk/typescript/tests/continue.test.ts. The proxy key allows you to route requests through Continue's infrastructure rather than calling providers directly.
How do I disable telemetry in the Continue CLI?
Set CONTINUE_CLI_ENABLE_TELEMETRY=0 and CONTINUE_METRICS_ENABLED=0 before running commands. According to extensions/cli/src/telemetry/telemetryService.ts, these variables completely disable metric collection and telemetry transmission. You can also set CONTINUE_ALLOW_ANONYMOUS_TELEMETRY=0 for legacy compatibility.
How do I configure Continue to work behind a corporate proxy?
Export HTTPS_PROXY (or lowercase https_proxy) with your proxy URL, and if needed, NODE_EXTRA_CA_CERTS pointing to your custom CA bundle. The fetch utility in packages/fetch/src/util.ts reads these variables for proxy routing, while packages/fetch/src/certs.ts handles the custom certificates.
What is CONTINUE_GLOBAL_DIR used for?
CONTINUE_GLOBAL_DIR overrides the default ~/.continue directory where the CLI stores configuration, indexes, and session data. This is essential for CI pipelines or ephemeral environments where you want to isolate Continue's state or point it to a pre-configured directory, as demonstrated in extensions/cli/vitest.global-dir-setup.ts.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →