Find and layer your settings.json files

configuration

// what it does

Settings load from four layers, highest wins: CLI flags and env vars, then system overrides (/etc/gemini-cli/settings.json), then project .gemini/settings.json, then user ~/.gemini/settings.json, then system defaults. Put personal preferences in the user file and shared team config in the project file so it can be committed. String values support $VAR and ${VAR} interpolation.

// shell

$ cat ~/.gemini/settings.json
$ cat .gemini/settings.json

// gotcha

A committed project .gemini/settings.json overrides each teammate's personal user settings for that repo, which surprises people whose theme or model choice stops applying — keep project settings limited to things the whole team should share. System-level files under /etc override projects and need root to edit.

// resources