Three-tier configuration files, merge priority, and common configuration items in Qoder CLI
The behavior of Qoder CLI can be customized through JSON configuration files (settings.json). The configuration uses a hierarchical design: the same setting can be defined at different levels and is ultimately merged into an effective value based on a fixed precedence. Understanding this hierarchy and merging rules is fundamental to managing personal preferences and team conventions.This page covers the locations of configuration files, merge precedence, and common configuration items. For a complete list of configuration items and environment variables, see Configuration Item Reference.
Qoder CLI reads configuration files from three levels:
Level
Path
Description
User Level
~/.qoder/settings.json
Personal preferences that apply to all projects for the current user.
Project-Level
<project>/.qoder/settings.json
Shared project configuration, committed to the repository and shared among team members.
Local Level
<project>/.qoder/settings.local.json
Personal overrides within a project, typically not committed to the repository.
The default configuration directory is ~/.qoder, which can be modified via the environment variable QODER_CONFIG_DIR. For the complete structure of the .qoder/ directory, see .qoder directory.
When the same configuration item appears at multiple levels, Qoder CLI merges them in the following order of precedence from lowest to highest, where higher precedence overrides lower precedence:
Local Level settings (<project>/.qoder/settings.local.json)
Configurations specified via command-line --settings (Highest precedence)
In other words: Local Level overrides Project-Level, Project-Level overrides User Level, and configurations explicitly passed via the command line take precedence over all files.
Configurations use deep merge rather than wholesale replacement:
Objects: Recursively merged field by field; only present fields are overridden, while the rest retain lower-precedence values.
Single values (strings, numbers, booleans): Directly overridden by higher precedence.
Arrays: Some configuration items (such as disable lists and exclude lists) use "union merge" to combine and deduplicate values across levels; other arrays are overridden by default.
Therefore, at the Project-Level, you only need to specify the fields you want to override, without copying the entire user configuration.
For security reasons, Project-Level and Local Level configurations are only applied when the current working directory is trusted. If the working directory is not trusted, Qoder CLI only loads User Level configurations and ignores settings.json and settings.local.json within the project. Folder Trust is controlled by security.folderTrust.enabled (enabled by default).
Configuration files are in JSON format (supporting // comments, see below). The top level is an object, and most configuration items are nested by group, with a few items located directly at the top level (such as outputStyle, language, and agent). For example:
The following lists the most frequently adjusted configuration items, organized by group. Items marked with "requires restart" require a restart to take effect after modification.
The following configuration items are written directly at the top level of the configuration file and do not belong to any group:
Configuration Item
Type
Default
Description
outputStyle
string
None
Name of the active Output Style (requires restart). Compatible with the general.outputStyle syntax, with top-level taking precedence. See Output Style.
language
string
None
Preferred language for AI responses (requires restart).
agent
string
None
Name of the Agent used for the main thread (requires restart).
In the Interactive interface: Run /settings to open the Settings Panel to directly view and adjust common configuration items.
Manually editing files: Open the settings.json for the corresponding level in an editor, and add or modify fields according to the tables above.
After modification, items not marked with "requires restart" usually take effect immediately; items marked with "requires restart" require restarting Qoder CLI.