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 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
# Gemini CLI configuration

Gemini CLI offers several ways to configure its behavior, including environment
variables, command-line arguments, and settings files. This document outlines
the different configuration methods and available settings.

## Configuration layers

Configuration is applied in the following order of precedence (lower numbers are
overridden by higher numbers):

1.  **Default values:** Hardcoded defaults within the application.
2.  **System defaults file:** System-wide default settings that can be
    overridden by other settings files.
3.  **User settings file:** Global settings for the current user.
4.  **Project settings file:** Project-specific settings.
5.  **System settings file:** System-wide settings that override all other
    settings files.
6.  **Environment variables:** System-wide or session-specific variables,
    potentially loaded from `.env` files.
7.  **Command-line arguments:** Values passed when launching the CLI.

## Settings files

Gemini CLI uses JSON settings files for persistent configuration. There are four
locations for these files:

<!-- prettier-ignore -->
> [!TIP]
> JSON-aware editors can use autocomplete and validation by pointing to
> the generated schema at `schemas/settings.schema.json` in this repository.
> When working outside the repo, reference the hosted schema at
> `https://raw.githubusercontent.com/google-gemini/gemini-cli/main/schemas/settings.schema.json`.

- **System defaults file:**
  - **Location:** `/etc/gemini-cli/system-defaults.json` (Linux),
    `C:\ProgramData\gemini-cli\system-defaults.json` (Windows) or
    `/Library/Application Support/GeminiCli/system-defaults.json` (macOS). The
    path can be overridden using the `GEMINI_CLI_SYSTEM_DEFAULTS_PATH`
    environment variable.
  - **Scope:** Provides a base layer of system-wide default settings. These
    settings have the lowest precedence and are intended to be overridden by
    user, project, or system override settings.
- **User settings file:**
  - **Location:** `~/.gemini/settings.json` (where `~` is your home directory).
  - **Scope:** Applies to all Gemini CLI sessions for the current user. User
    settings override system defaults.
- **Project settings file:**
  - **Location:** `.gemini/settings.json` within your project's root directory.
  - **Scope:** Applies only when running Gemini CLI from that specific project.
    Project settings override user settings and system defaults.
- **System settings file:**
  - **Location:** `/etc/gemini-cli/settings.json` (Linux),
    `C:\ProgramData\gemini-cli\settings.json` (Windows) or
    `/Library/Application Support/GeminiCli/settings.json` (macOS). The path can
    be overridden using the `GEMINI_CLI_SYSTEM_SETTINGS_PATH` environment
    variable.
  - **Scope:** Applies to all Gemini CLI sessions on the system, for all users.
    System settings act as overrides, taking precedence over all other settings
    files. May be useful for system administrators at enterprises to have
    controls over users' Gemini CLI setups.

**Note on environment variables in settings:** String values within your
`settings.json` and `gemini-extension.json` files can reference environment
variables using `$VAR_NAME`, `${VAR_NAME}`, or `${VAR_NAME:-DEFAULT_VALUE}`
syntax. These variables will be automatically resolved when the settings are
loaded. For example, if you have an environment variable `MY_API_TOKEN`, you
could use it in `settings.json` like this: `"apiKey": "$MY_API_TOKEN"`. If you
want to provide a fallback value, use `${MY_API_TOKEN:-default-token}`.
Additionally, each extension can have its own `.env` file in its directory,
which will be loaded automatically.

**Note for Enterprise Users:** For guidance on deploying and managing Gemini CLI
in a corporate environment, see the
[Enterprise Configuration](../cli/enterprise.md) documentation.

### The `.gemini` directory in your project

In addition to a project settings file, a project's `.gemini` directory can
contain other project-specific files related to Gemini CLI's operation, such as:

- [Custom sandbox profiles](#sandboxing) (for example,
  `.gemini/sandbox-macos-custom.sb`, `.gemini/sandbox.Dockerfile`).

### Available settings in `settings.json`

Settings are organized into categories. All settings should be placed within
their corresponding top-level category object in your `settings.json` file.

<!-- SETTINGS-AUTOGEN:START -->

#### `policyPaths`

- **`policyPaths`** (array):
  - **Description:** Additional policy files or directories to load.
  - **Default:** `[]`
  - **Requires restart:** Yes

#### `adminPolicyPaths`

- **`adminPolicyPaths`** (array):
  - **Description:** Additional admin policy files or directories to load.
  - **Default:** `[]`
  - **Requires restart:** Yes

#### `general`

- **`general.preferredEditor`** (enum):

  - **Description:** The preferred editor to open files in. Must be one of the
    built-in supported identifiers. Use /editor in the CLI to pick
    interactively, or leave unset to use $VISUAL/$EDITOR.
  - **Default:** `undefined`
  - **Values:** `"vscode"`, `"vscodium"`, `"windsurf"`, `"cursor"`, `"zed"`,
    `"antigravity"`, `"sublimetext"`, `"lapce"`, `"nova"`, `"bbedit"`, `"vim"`,
    `"neovim"`, `"emacs"`, `"hx"`, `"emacsclient"`, `"micro"`

- **`general.openEditorInNewWindow`** (boolean):

  - **Description:** Open VS Code-family editors in a new window when editing
    files.
  - **Default:** `false`

- **`general.vimMode`** (boolean):

  - **Description:** Enable Vim keybindings
  - **Default:** `false`

- **`general.defaultApprovalMode`** (enum):

  - **Description:** The default approval mode for tool execution. 'default'
    prompts for approval, 'auto_edit' auto-approves edit tools, and 'plan' is
    read-only mode. YOLO mode (auto-approve all actions) can only be enabled via
    command line (--yolo or --approval-mode=yolo).
  - **Default:** `"default"`
  - **Values:** `"default"`, `"auto_edit"`, `"plan"`

- **`general.devtools`** (boolean):

  - **Description:** Enable DevTools inspector on launch.
  - **Default:** `false`

- **`general.enableAutoUpdate`** (boolean):

  - **Description:** Enable automatic updates.
  - **Default:** `true`

- **`general.enableAutoUpdateNotification`** (boolean):

  - **Description:** Enable update notification prompts.
  - **Default:** `true`

- **`general.enableNotifications`** (boolean):

  - **Description:** Enable terminal run-event notifications for action-required
    prompts and session completion.
  - **Default:** `false`

- **`general.notificationMethod`** (enum):

  - **Description:** How to send terminal notifications.
  - **Default:** `"auto"`
  - **Values:** `"auto"`, `"osc9"`, `"osc777"`, `"bell"`

- **`general.checkpointing.enabled`** (boolean):

  - **Description:** Enable session checkpointing for recovery
  - **Default:** `false`
  - **Requires restart:** Yes

- **`general.plan.enabled`** (boolean):

  - **Description:** Enable Plan Mode for read-only safety during planning.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`general.plan.directory`** (string):

  - **Description:** The directory where planning artifacts are stored. If not
    specified, defaults to the system temporary directory. A custom directory
    requires a policy to allow write access in Plan Mode.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`general.plan.modelRouting`** (boolean):

  - **Description:** Automatically switch between Pro and Flash models based on
    Plan Mode status. Uses Pro for the planning phase and Flash for the
    implementation phase.
  - **Default:** `true`

- **`general.retryFetchErrors`** (boolean):

  - **Description:** Retry on "exception TypeError: fetch failed sending
    request" errors.
  - **Default:** `true`

- **`general.maxAttempts`** (number):

  - **Description:** Maximum number of attempts for requests to the main chat
    model. Cannot exceed 10.
  - **Default:** `10`

- **`general.debugKeystrokeLogging`** (boolean):

  - **Description:** Enable debug logging of keystrokes to the console.
  - **Default:** `false`

- **`general.sessionRetention.enabled`** (boolean):

  - **Description:** Enable automatic session cleanup
  - **Default:** `true`

- **`general.sessionRetention.maxAge`** (string):

  - **Description:** Automatically delete chats older than this time period
    (e.g., "30d", "7d", "24h", "1w")
  - **Default:** `"30d"`

- **`general.sessionRetention.maxCount`** (number):

  - **Description:** Alternative: Maximum number of sessions to keep (most
    recent)
  - **Default:** `undefined`

- **`general.sessionRetention.minRetention`** (string):

  - **Description:** Minimum retention period (safety limit, defaults to "1d")
  - **Default:** `"1d"`

- **`general.topicUpdateNarration`** (boolean):

  - **Description:** Enable the Topic & Update communication model for reduced
    chattiness and structured progress reporting.
  - **Default:** `true`

- **`general.logRagSnippets`** (boolean):
  - **Description:** Log full Code Customization (RAG) retrieved snippets to a
    local file for debugging.
  - **Default:** `false`

#### `output`

- **`output.format`** (enum):
  - **Description:** The format of the CLI output. Can be `text` or `json`.
  - **Default:** `"text"`
  - **Values:** `"text"`, `"json"`

#### `ui`

- **`ui.debugRainbow`** (boolean):

  - **Description:** Enable debug rainbow rendering. Only useful for debugging
    rendering bugs and performance issues.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`ui.theme`** (string):

  - **Description:** The color theme for the UI. See the CLI themes guide for
    available options.
  - **Default:** `undefined`

- **`ui.autoThemeSwitching`** (boolean):

  - **Description:** Automatically switch between default light and dark themes
    based on terminal background color.
  - **Default:** `true`

- **`ui.terminalBackgroundPollingInterval`** (number):

  - **Description:** Interval in seconds to poll the terminal background color.
  - **Default:** `60`

- **`ui.customThemes`** (object):

  - **Description:** Custom theme definitions.
  - **Default:** `{}`

- **`ui.hideWindowTitle`** (boolean):

  - **Description:** Hide the window title bar
  - **Default:** `false`
  - **Requires restart:** Yes

- **`ui.inlineThinkingMode`** (enum):

  - **Description:** Display model thinking inline: off or full.
  - **Default:** `"off"`
  - **Values:** `"off"`, `"full"`

- **`ui.showStatusInTitle`** (boolean):

  - **Description:** Show Gemini CLI model thoughts in the terminal window title
    during the working phase
  - **Default:** `false`

- **`ui.dynamicWindowTitle`** (boolean):

  - **Description:** Update the terminal window title with current status icons
    (Ready: ◇, Action Required: ✋, Working: ✦)
  - **Default:** `true`

- **`ui.showHomeDirectoryWarning`** (boolean):

  - **Description:** Show a warning when running Gemini CLI in the home
    directory.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`ui.showCompatibilityWarnings`** (boolean):

  - **Description:** Show warnings about terminal or OS compatibility issues.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`ui.hideTips`** (boolean):

  - **Description:** Hide helpful tips in the UI
  - **Default:** `false`

- **`ui.escapePastedAtSymbols`** (boolean):

  - **Description:** When enabled, @ symbols in pasted text are escaped to
    prevent unintended @path expansion.
  - **Default:** `false`

- **`ui.showShortcutsHint`** (boolean):

  - **Description:** Show the "? for shortcuts" hint above the input.
  - **Default:** `true`

- **`ui.compactToolOutput`** (boolean):

  - **Description:** Display tool outputs (like directory listings and file
    reads) in a compact, structured format.
  - **Default:** `true`

- **`ui.hideBanner`** (boolean):

  - **Description:** Hide the application banner
  - **Default:** `false`

- **`ui.hideContextSummary`** (boolean):

  - **Description:** Hide the context summary (GEMINI.md, MCP servers) above the
    input.
  - **Default:** `false`

- **`ui.footer.items`** (array):

  - **Description:** List of item IDs to display in the footer. Rendered in
    order
  - **Default:** `undefined`

- **`ui.footer.showLabels`** (boolean):

  - **Description:** Display a second line above the footer items with
    descriptive headers (e.g., /model).
  - **Default:** `true`

- **`ui.footer.hideCWD`** (boolean):

  - **Description:** Hide the current working directory in the footer.
  - **Default:** `false`

- **`ui.footer.hideSandboxStatus`** (boolean):

  - **Description:** Hide the sandbox status indicator in the footer.
  - **Default:** `false`

- **`ui.footer.hideModelInfo`** (boolean):

  - **Description:** Hide the model name and context usage in the footer.
  - **Default:** `false`

- **`ui.footer.hideContextPercentage`** (boolean):

  - **Description:** Hides the context window usage percentage.
  - **Default:** `true`

- **`ui.hideFooter`** (boolean):

  - **Description:** Hide the footer from the UI
  - **Default:** `false`

- **`ui.collapseDrawerDuringApproval`** (boolean):

  - **Description:** Whether to collapse the UI drawer when a tool is awaiting
    confirmation.
  - **Default:** `true`

- **`ui.showMemoryUsage`** (boolean):

  - **Description:** Display memory usage information in the UI
  - **Default:** `false`

- **`ui.showLineNumbers`** (boolean):

  - **Description:** Show line numbers in the chat.
  - **Default:** `true`

- **`ui.showCitations`** (boolean):

  - **Description:** Show citations for generated text in the chat.
  - **Default:** `false`

- **`ui.showModelInfoInChat`** (boolean):

  - **Description:** Show the model name in the chat for each model turn.
  - **Default:** `false`

- **`ui.showUserIdentity`** (boolean):

  - **Description:** Show the signed-in user's identity (e.g. email) in the UI.
  - **Default:** `true`

- **`ui.useAlternateBuffer`** (boolean):

  - **Description:** Use an alternate screen buffer for the UI, preserving shell
    history.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`ui.renderProcess`** (boolean):

  - **Description:** Enable Ink render process for the UI.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`ui.terminalBuffer`** (boolean):

  - **Description:** Use the new terminal buffer architecture for rendering.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`ui.useBackgroundColor`** (boolean):

  - **Description:** Whether to use background colors in the UI.
  - **Default:** `true`

- **`ui.incrementalRendering`** (boolean):

  - **Description:** Enable incremental rendering for the UI. This option will
    reduce flickering but may cause rendering artifacts. Only supported when
    useAlternateBuffer is enabled.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`ui.showSpinner`** (boolean):

  - **Description:** Show the spinner during operations.
  - **Default:** `true`

- **`ui.loadingPhrases`** (enum):

  - **Description:** What to show while the model is working: tips, witty
    comments, all, or off.
  - **Default:** `"off"`
  - **Values:** `"tips"`, `"witty"`, `"all"`, `"off"`

- **`ui.errorVerbosity`** (enum):

  - **Description:** Controls whether recoverable errors are hidden (low) or
    fully shown (full).
  - **Default:** `"low"`
  - **Values:** `"low"`, `"full"`

- **`ui.customWittyPhrases`** (array):

  - **Description:** Custom witty phrases to display during loading. When
    provided, the CLI cycles through these instead of the defaults.
  - **Default:** `[]`

- **`ui.accessibility.enableLoadingPhrases`** (boolean):

  - **Description:** @deprecated Use ui.loadingPhrases instead. Enable loading
    phrases during operations.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`ui.accessibility.screenReader`** (boolean):
  - **Description:** Render output in plain-text to be more screen reader
    accessible
  - **Default:** `false`
  - **Requires restart:** Yes

#### `ide`

- **`ide.enabled`** (boolean):

  - **Description:** Enable IDE integration mode.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`ide.hasSeenNudge`** (boolean):
  - **Description:** Whether the user has seen the IDE integration nudge.
  - **Default:** `false`

#### `privacy`

- **`privacy.usageStatisticsEnabled`** (boolean):
  - **Description:** Enable collection of usage statistics
  - **Default:** `true`
  - **Requires restart:** Yes

#### `billing`

- **`billing.overageStrategy`** (enum):

  - **Description:** How to handle quota exhaustion when AI credits are
    available. 'ask' prompts each time, 'always' automatically uses credits,
    'never' disables credit usage.
  - **Default:** `"ask"`
  - **Values:** `"ask"`, `"always"`, `"never"`

- **`billing.vertexAi.requestType`** (enum):

  - **Description:** Sets the X-Vertex-AI-LLM-Request-Type header for Vertex AI
    requests.
  - **Default:** `undefined`
  - **Values:** `"dedicated"`, `"shared"`
  - **Requires restart:** Yes

- **`billing.vertexAi.sharedRequestType`** (enum):
  - **Description:** Sets the X-Vertex-AI-LLM-Shared-Request-Type header for
    Vertex AI requests.
  - **Default:** `undefined`
  - **Values:** `"priority"`, `"flex"`
  - **Requires restart:** Yes

#### `model`

- **`model.name`** (string):

  - **Description:** The Gemini model to use for conversations.
  - **Default:** `undefined`

- **`model.maxSessionTurns`** (number):

  - **Description:** Maximum number of user/model/tool turns to keep in a
    session. -1 means unlimited.
  - **Default:** `-1`

- **`model.summarizeToolOutput`** (object):

  - **Description:** Enables or disables summarization of tool output. Configure
    per-tool token budgets (for example {"run_shell_command": {"tokenBudget":
    2000}}). Currently only the run_shell_command tool supports summarization.
  - **Default:** `undefined`

- **`model.compressionThreshold`** (number):

  - **Description:** The fraction of context usage at which to trigger context
    compression (e.g. 0.2, 0.3).
  - **Default:** `0.5`
  - **Requires restart:** Yes

- **`model.disableLoopDetection`** (boolean):

  - **Description:** Disable automatic detection and prevention of infinite
    loops.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`model.skipNextSpeakerCheck`** (boolean):
  - **Description:** Skip the next speaker check.
  - **Default:** `true`

#### `modelConfigs`

- **`modelConfigs.aliases`** (object):

  - **Description:** Named presets for model configs. Can be used in place of a
    model name and can inherit from other aliases using an `extends` property.
  - **Default:**

    ```json
    {
      "base": {
        "modelConfig": {
          "generateContentConfig": {
            "temperature": 0,
            "topP": 1
          }
        }
      },
      "chat-base": {
        "extends": "base",
        "modelConfig": {
          "generateContentConfig": {
            "thinkingConfig": {
              "includeThoughts": true
            },
            "temperature": 1,
            "topP": 0.95,
            "topK": 64
          }
        }
      },
      "chat-base-2.5": {
        "extends": "chat-base",
        "modelConfig": {
          "generateContentConfig": {
            "thinkingConfig": {
              "thinkingBudget": 8192
            }
          }
        }
      },
      "chat-base-3": {
        "extends": "chat-base",
        "modelConfig": {
          "generateContentConfig": {
            "thinkingConfig": {
              "thinkingLevel": "HIGH"
            }
          }
        }
      },
      "gemini-3-pro-preview": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemini-3-pro-preview"
        }
      },
      "gemini-3-flash-preview": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemini-3-flash-preview"
        }
      },
      "gemini-3.1-pro-preview": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemini-3.1-pro-preview"
        }
      },
      "gemini-3.1-pro-preview-customtools": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemini-3.1-pro-preview-customtools"
        }
      },
      "gemini-3.1-flash-lite-preview": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemini-3.1-flash-lite-preview"
        }
      },
      "gemini-2.5-pro": {
        "extends": "chat-base-2.5",
        "modelConfig": {
          "model": "gemini-2.5-pro"
        }
      },
      "gemini-2.5-flash": {
        "extends": "chat-base-2.5",
        "modelConfig": {
          "model": "gemini-2.5-flash"
        }
      },
      "gemini-2.5-flash-lite": {
        "extends": "chat-base-2.5",
        "modelConfig": {
          "model": "gemini-2.5-flash-lite"
        }
      },
      "gemini-3.1-flash-lite": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemini-3.1-flash-lite"
        }
      },
      "gemini-3.5-flash": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemini-3.5-flash"
        }
      },
      "gemma-4-31b-it": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemma-4-31b-it"
        }
      },
      "gemma-4-26b-a4b-it": {
        "extends": "chat-base-3",
        "modelConfig": {
          "model": "gemma-4-26b-a4b-it"
        }
      },
      "gemini-2.5-flash-base": {
        "extends": "base",
        "modelConfig": {
          "model": "gemini-2.5-flash"
        }
      },
      "gemini-3-flash-base": {
        "extends": "base",
        "modelConfig": {
          "model": "gemini-3-flash-preview"
        }
      },
      "gemini-3.5-flash-base": {
        "extends": "base",
        "modelConfig": {
          "model": "gemini-3.5-flash"
        }
      },
      "classifier": {
        "extends": "base",
        "modelConfig": {
          "model": "flash-lite",
          "generateContentConfig": {
            "maxOutputTokens": 1024,
            "thinkingConfig": {
              "thinkingBudget": 512
            }
          }
        }
      },
      "prompt-completion": {
        "extends": "base",
        "modelConfig": {
          "model": "flash-lite",
          "generateContentConfig": {
            "temperature": 0.3,
            "maxOutputTokens": 16000,
            "thinkingConfig": {
              "thinkingBudget": 0
            }
          }
        }
      },
      "fast-ack-helper": {
        "extends": "base",
        "modelConfig": {
          "model": "flash-lite",
          "generateContentConfig": {
            "temperature": 0.2,
            "maxOutputTokens": 120,
            "thinkingConfig": {
              "thinkingBudget": 0
            }
          }
        }
      },
      "edit-corrector": {
        "extends": "base",
        "modelConfig": {
          "model": "flash-lite",
          "generateContentConfig": {
            "thinkingConfig": {
              "thinkingBudget": 0
            }
          }
        }
      },
      "summarizer-default": {
        "extends": "base",
        "modelConfig": {
          "model": "flash-lite",
          "generateContentConfig": {
            "maxOutputTokens": 2000
          }
        }
      },
      "summarizer-shell": {
        "extends": "base",
        "modelConfig": {
          "model": "flash-lite",
          "generateContentConfig": {
            "maxOutputTokens": 2000
          }
        }
      },
      "web-search": {
        "extends": "gemini-3-flash-base",
        "modelConfig": {
          "generateContentConfig": {
            "tools": [
              {
                "googleSearch": {}
              }
            ]
          }
        }
      },
      "web-fetch": {
        "extends": "gemini-3-flash-base",
        "modelConfig": {
          "generateContentConfig": {
            "tools": [
              {
                "urlContext": {}
              }
            ]
          }
        }
      },
      "web-fetch-fallback": {
        "extends": "gemini-3-flash-base",
        "modelConfig": {}
      },
      "loop-detection": {
        "extends": "gemini-3-flash-base",
        "modelConfig": {}
      },
      "loop-detection-double-check": {
        "extends": "base",
        "modelConfig": {
          "model": "gemini-3-pro-preview"
        }
      },
      "llm-edit-fixer": {
        "extends": "gemini-3-flash-base",
        "modelConfig": {}
      },
      "next-speaker-checker": {
        "extends": "gemini-3-flash-base",
        "modelConfig": {}
      },
      "context-snapshotter": {
        "extends": "gemini-3-flash-base",
        "modelConfig": {
          "generateContentConfig": {
            "thinkingConfig": {
              "thinkingLevel": "HIGH"
            },
            "temperature": 1,
            "topP": 0.95,
            "topK": 64
          }
        }
      },
      "chat-compression-3-pro": {
        "modelConfig": {
          "model": "gemini-3-pro-preview"
        }
      },
      "chat-compression-3-flash": {
        "modelConfig": {
          "model": "gemini-3-flash-preview"
        }
      },
      "chat-compression-3.1-flash-lite": {
        "modelConfig": {
          "model": "gemini-3.1-flash-lite"
        }
      },
      "chat-compression-2.5-pro": {
        "modelConfig": {
          "model": "gemini-2.5-pro"
        }
      },
      "chat-compression-2.5-flash": {
        "modelConfig": {
          "model": "gemini-2.5-flash"
        }
      },
      "chat-compression-2.5-flash-lite": {
        "modelConfig": {
          "model": "gemini-2.5-flash-lite"
        }
      },
      "chat-compression-default": {
        "modelConfig": {
          "model": "gemini-3-pro-preview"
        }
      },
      "agent-history-provider-summarizer": {
        "modelConfig": {
          "model": "gemini-3-flash-preview"
        }
      }
    }
    ```

- **`modelConfigs.customAliases`** (object):

  - **Description:** Custom named presets for model configs. These are merged
    with (and override) the built-in aliases.
  - **Default:** `{}`

- **`modelConfigs.customOverrides`** (array):

  - **Description:** Custom model config overrides. These are merged with (and
    added to) the built-in overrides.
  - **Default:** `[]`

- **`modelConfigs.overrides`** (array):

  - **Description:** Apply specific configuration overrides based on matches,
    with a primary key of model (or alias). The most specific match will be
    used.
  - **Default:** `[]`

- **`modelConfigs.modelDefinitions`** (object):

  - **Description:** Registry of model metadata, including tier, family, and
    features.
  - **Default:**

    ```json
    {
      "gemini-3.1-flash-lite": {
        "tier": "flash-lite",
        "family": "gemini-3",
        "isPreview": false,
        "isVisible": true,
        "features": {
          "thinking": false,
          "multimodalToolUse": true
        }
      },
      "gemini-3.1-pro-preview": {
        "tier": "pro",
        "family": "gemini-3",
        "isPreview": true,
        "isVisible": true,
        "features": {
          "thinking": true,
          "multimodalToolUse": true
        }
      },
      "gemini-3.1-pro-preview-customtools": {
        "tier": "pro",
        "family": "gemini-3",
        "isPreview": true,
        "isVisible": false,
        "features": {
          "thinking": true,
          "multimodalToolUse": true
        }
      },
      "gemini-3-pro-preview": {
        "tier": "pro",
        "family": "gemini-3",
        "isPreview": true,
        "isVisible": true,
        "features": {
          "thinking": true,
          "multimodalToolUse": true
        }
      },
      "gemini-3-flash-preview": {
        "tier": "flash",
        "family": "gemini-3",
        "isPreview": true,
        "isVisible": true,
        "features": {
          "thinking": false,
          "multimodalToolUse": true
        }
      },
      "gemini-3.5-flash": {
        "tier": "flash",
        "family": "gemini-3",
        "isPreview": false,
        "isVisible": true,
        "features": {
          "thinking": false,
          "multimodalToolUse": true
        }
      },
      "gemini-2.5-pro": {
        "tier": "pro",
        "family": "gemini-2.5",
        "isPreview": false,
        "isVisible": true,
        "features": {
          "thinking": false,
          "multimodalToolUse": false
        }
      },
      "gemini-2.5-flash": {
        "tier": "flash",
        "family": "gemini-2.5",
        "isPreview": false,
        "isVisible": true,
        "features": {
          "thinking": false,
          "multimodalToolUse": false
        }
      },
      "gemini-2.5-flash-lite": {
        "tier": "flash-lite",
        "family": "gemini-2.5",
        "isPreview": false,
        "isVisible": true,
        "features": {
          "thinking": false,
          "multimodalToolUse": false
        }
      },
      "gemma-4-31b-it": {
        "displayName": "gemma-4-31b-it",
        "tier": "custom",
        "family": "gemma-4",
        "isPreview": false,
        "isVisible": true,
        "features": {
          "thinking": true,
          "multimodalToolUse": false
        }
      },
      "gemma-4-26b-a4b-it": {
        "displayName": "gemma-4-26b-a4b-it",
        "tier": "custom",
        "family": "gemma-4",
        "isPreview": false,
        "isVisible": true,
        "features": {
          "thinking": true,
          "multimodalToolUse": false
        }
      },
      "auto": {
        "displayName": "Auto",
        "tier": "auto",
        "isPreview": true,
        "isVisible": true,
        "features": {
          "thinking": true,
          "multimodalToolUse": false
        }
      },
      "pro": {
        "tier": "pro",
        "isPreview": false,
        "isVisible": false,
        "features": {
          "thinking": true,
          "multimodalToolUse": false
        }
      },
      "flash": {
        "tier": "flash",
        "isPreview": false,
        "isVisible": false,
        "features": {
          "thinking": false,
          "multimodalToolUse": false
        }
      },
      "flash-lite": {
        "tier": "flash-lite",
        "isPreview": false,
        "isVisible": false,
        "features": {
          "thinking": false,
          "multimodalToolUse": false
        }
      },
      "auto-gemini-3": {
        "tier": "auto",
        "family": "gemini-3",
        "isPreview": true,
        "isVisible": false
      },
      "auto-gemini-2.5": {
        "tier": "auto",
        "family": "gemini-2.5",
        "isPreview": false,
        "isVisible": false
      }
    }
    ```

  - **Requires restart:** Yes

- **`modelConfigs.modelIdResolutions`** (object):

  - **Description:** Rules for resolving requested model names to concrete model
    IDs based on context.
  - **Default:**

    ```json
    {
      "gemma-4-31b-it": {
        "default": "gemma-4-31b-it"
      },
      "gemma-4-26b-a4b-it": {
        "default": "gemma-4-26b-a4b-it"
      },
      "gemini-3.1-pro-preview": {
        "default": "gemini-3.1-pro-preview",
        "contexts": [
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-pro"
          },
          {
            "condition": {
              "useCustomTools": true
            },
            "target": "gemini-3.1-pro-preview-customtools"
          }
        ]
      },
      "gemini-3.1-pro-preview-customtools": {
        "default": "gemini-3.1-pro-preview-customtools",
        "contexts": [
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-pro"
          }
        ]
      },
      "gemini-3-flash-preview": {
        "default": "gemini-3-flash-preview",
        "contexts": [
          {
            "condition": {
              "hasAccessToPreview": false,
              "useGemini3_5Flash": true
            },
            "target": "gemini-3.5-flash"
          },
          {
            "condition": {
              "hasAccessToPreview": false,
              "useGemini3_5Flash": false
            },
            "target": "gemini-2.5-flash"
          }
        ]
      },
      "gemini-3.5-flash": {
        "default": "gemini-3.5-flash",
        "contexts": [
          {
            "condition": {
              "useGemini3_5Flash": false,
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-flash"
          },
          {
            "condition": {
              "useGemini3_5Flash": false
            },
            "target": "gemini-3-flash-preview"
          }
        ]
      },
      "gemini-2.5-flash": {
        "default": "gemini-2.5-flash",
        "contexts": [
          {
            "condition": {
              "useGemini3_5Flash": true
            },
            "target": "gemini-3.5-flash"
          }
        ]
      },
      "gemini-3-pro-preview": {
        "default": "gemini-3-pro-preview",
        "contexts": [
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-pro"
          },
          {
            "condition": {
              "useGemini3_1": true,
              "useCustomTools": true
            },
            "target": "gemini-3.1-pro-preview-customtools"
          },
          {
            "condition": {
              "useGemini3_1": true
            },
            "target": "gemini-3.1-pro-preview"
          }
        ]
      },
      "auto": {
        "default": "gemini-3-pro-preview",
        "contexts": [
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-pro"
          },
          {
            "condition": {
              "useGemini3_1": true,
              "useCustomTools": true
            },
            "target": "gemini-3.1-pro-preview-customtools"
          },
          {
            "condition": {
              "useGemini3_1": true
            },
            "target": "gemini-3.1-pro-preview"
          }
        ]
      },
      "pro": {
        "default": "gemini-3-pro-preview",
        "contexts": [
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-pro"
          },
          {
            "condition": {
              "useGemini3_1": true,
              "useCustomTools": true
            },
            "target": "gemini-3.1-pro-preview-customtools"
          },
          {
            "condition": {
              "useGemini3_1": true
            },
            "target": "gemini-3.1-pro-preview"
          }
        ]
      },
      "gemini-3.1-flash-lite": {
        "default": "gemini-3.1-flash-lite"
      },
      "flash": {
        "default": "gemini-3-flash-preview",
        "contexts": [
          {
            "condition": {
              "useGemini3_5Flash": true
            },
            "target": "gemini-3.5-flash"
          },
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-flash"
          }
        ]
      },
      "flash-lite": {
        "default": "gemini-3.1-flash-lite"
      },
      "auto-gemini-3": {
        "default": "gemini-3-pro-preview",
        "contexts": [
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-pro"
          },
          {
            "condition": {
              "useGemini3_1": true,
              "useCustomTools": true
            },
            "target": "gemini-3.1-pro-preview-customtools"
          },
          {
            "condition": {
              "useGemini3_1": true
            },
            "target": "gemini-3.1-pro-preview"
          }
        ]
      },
      "auto-gemini-2.5": {
        "default": "gemini-2.5-pro"
      }
    }
    ```

  - **Requires restart:** Yes

- **`modelConfigs.classifierIdResolutions`** (object):

  - **Description:** Rules for resolving classifier tiers (flash, pro) to
    concrete model IDs.
  - **Default:**

    ```json
    {
      "flash": {
        "default": "gemini-3-flash-preview",
        "contexts": [
          {
            "condition": {
              "useGemini3_5Flash": true
            },
            "target": "gemini-3.5-flash"
          },
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-flash"
          },
          {
            "condition": {
              "requestedModels": ["gemini-2.5-pro", "auto-gemini-2.5"]
            },
            "target": "gemini-2.5-flash"
          }
        ]
      },
      "pro": {
        "default": "gemini-3-pro-preview",
        "contexts": [
          {
            "condition": {
              "hasAccessToPreview": false
            },
            "target": "gemini-2.5-pro"
          },
          {
            "condition": {
              "requestedModels": ["gemini-2.5-pro", "auto-gemini-2.5"]
            },
            "target": "gemini-2.5-pro"
          },
          {
            "condition": {
              "useGemini3_1": true,
              "useCustomTools": true
            },
            "target": "gemini-3.1-pro-preview-customtools"
          },
          {
            "condition": {
              "useGemini3_1": true
            },
            "target": "gemini-3.1-pro-preview"
          }
        ]
      }
    }
    ```

  - **Requires restart:** Yes

- **`modelConfigs.modelChains`** (object):

  - **Description:** Availability policy chains defining fallback behavior for
    models.
  - **Default:**

    ```json
    {
      "preview": [
        {
          "model": "gemini-3-pro-preview",
          "actions": {
            "terminal": "prompt",
            "transient": "prompt",
            "not_found": "prompt",
            "unknown": "prompt"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "terminal",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        },
        {
          "model": "gemini-3-flash-preview",
          "isLastResort": true,
          "maxAttempts": 10,
          "actions": {
            "terminal": "prompt",
            "transient": "prompt",
            "not_found": "prompt",
            "unknown": "prompt"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "terminal",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        }
      ],
      "auto-preview": [
        {
          "model": "gemini-3-pro-preview",
          "maxAttempts": 3,
          "actions": {
            "terminal": "prompt",
            "transient": "silent",
            "not_found": "prompt",
            "unknown": "prompt"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "sticky_retry",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        },
        {
          "model": "gemini-3-flash-preview",
          "isLastResort": true,
          "maxAttempts": 10,
          "actions": {
            "terminal": "prompt",
            "transient": "prompt",
            "not_found": "prompt",
            "unknown": "prompt"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "terminal",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        }
      ],
      "default": [
        {
          "model": "gemini-2.5-pro",
          "actions": {
            "terminal": "prompt",
            "transient": "prompt",
            "not_found": "prompt",
            "unknown": "prompt"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "sticky_retry",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        },
        {
          "model": "gemini-2.5-flash",
          "isLastResort": true,
          "maxAttempts": 10,
          "actions": {
            "terminal": "prompt",
            "transient": "prompt",
            "not_found": "prompt",
            "unknown": "prompt"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "terminal",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        }
      ],
      "auto-default": [
        {
          "model": "gemini-2.5-pro",
          "maxAttempts": 3,
          "actions": {
            "terminal": "prompt",
            "transient": "silent",
            "not_found": "prompt",
            "unknown": "prompt"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "sticky_retry",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        },
        {
          "model": "gemini-2.5-flash",
          "isLastResort": true,
          "maxAttempts": 10,
          "actions": {
            "terminal": "prompt",
            "transient": "prompt",
            "not_found": "prompt",
            "unknown": "prompt"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "terminal",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        }
      ],
      "lite": [
        {
          "model": "flash-lite",
          "actions": {
            "terminal": "silent",
            "transient": "silent",
            "not_found": "silent",
            "unknown": "silent"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "terminal",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        },
        {
          "model": "gemini-2.5-flash",
          "actions": {
            "terminal": "silent",
            "transient": "silent",
            "not_found": "silent",
            "unknown": "silent"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "terminal",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        },
        {
          "model": "gemini-2.5-pro",
          "isLastResort": true,
          "actions": {
            "terminal": "silent",
            "transient": "silent",
            "not_found": "silent",
            "unknown": "silent"
          },
          "stateTransitions": {
            "terminal": "terminal",
            "transient": "terminal",
            "not_found": "terminal",
            "unknown": "terminal"
          }
        }
      ]
    }
    ```

  - **Requires restart:** Yes

#### `agents`

- **`agents.overrides`** (object):

  - **Description:** Override settings for specific agents, e.g. to disable the
    agent, set a custom model config, or run config.
  - **Default:** `{}`
  - **Requires restart:** Yes

- **`agents.browser.sessionMode`** (enum):

  - **Description:** Session mode: 'persistent', 'isolated', or 'existing'.
  - **Default:** `"persistent"`
  - **Values:** `"persistent"`, `"isolated"`, `"existing"`
  - **Requires restart:** Yes

- **`agents.browser.headless`** (boolean):

  - **Description:** Run browser in headless mode.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`agents.browser.profilePath`** (string):

  - **Description:** Path to browser profile directory for session persistence.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`agents.browser.visualModel`** (string):

  - **Description:** Model for the visual agent's analyze_screenshot tool. When
    set, enables the tool.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`agents.browser.allowedDomains`** (array):

  - **Description:** A list of allowed domains for the browser agent (e.g.,
    ["github.com", "*.google.com"]).
  - **Default:**

    ```json
    ["github.com", "*.google.com", "localhost"]
    ```

  - **Requires restart:** Yes

- **`agents.browser.disableUserInput`** (boolean):

  - **Description:** Disable user input on browser window during automation.
  - **Default:** `true`

- **`agents.browser.maxActionsPerTask`** (number):

  - **Description:** The maximum number of tool calls allowed per browser task.
    Enforcement is hard: the agent will be terminated when the limit is reached.
  - **Default:** `100`

- **`agents.browser.confirmSensitiveActions`** (boolean):

  - **Description:** Require manual confirmation for sensitive browser actions
    (e.g., fill_form, evaluate_script).
  - **Default:** `false`
  - **Requires restart:** Yes

- **`agents.browser.blockFileUploads`** (boolean):
  - **Description:** Hard-block file upload requests from the browser agent.
  - **Default:** `false`
  - **Requires restart:** Yes

#### `context`

- **`context.fileName`** (string | string[]):

  - **Description:** The name of the context file or files to load into memory.
    Accepts either a single string or an array of strings.
  - **Default:** `undefined`

- **`context.importFormat`** (string):

  - **Description:** The format to use when importing memory.
  - **Default:** `undefined`

- **`context.includeDirectoryTree`** (boolean):

  - **Description:** Whether to include the directory tree of the current
    working directory in the initial request to the model.
  - **Default:** `true`

- **`context.discoveryMaxDirs`** (number):

  - **Description:** Maximum number of directories to search for memory.
  - **Default:** `200`

- **`context.memoryBoundaryMarkers`** (array):

  - **Description:** File or directory names that mark the boundary for
    GEMINI.md discovery. The upward traversal stops at the first directory
    containing any of these markers. An empty array disables parent traversal.
  - **Default:**

    ```json
    [".git"]
    ```

  - **Requires restart:** Yes

- **`context.includeDirectories`** (array):

  - **Description:** Additional directories to include in the workspace context.
    Missing directories will be skipped with a warning.
  - **Default:** `[]`

- **`context.loadMemoryFromIncludeDirectories`** (boolean):

  - **Description:** Controls how /memory reload loads GEMINI.md files. When
    true, include directories are scanned; when false, only the current
    directory is used.
  - **Default:** `false`

- **`context.fileFiltering.respectGitIgnore`** (boolean):

  - **Description:** Respect .gitignore files when searching.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`context.fileFiltering.respectGeminiIgnore`** (boolean):

  - **Description:** Respect .geminiignore files when searching.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`context.fileFiltering.enableFileWatcher`** (boolean):

  - **Description:** Enable file watcher updates for @ file suggestions
    (experimental).
  - **Default:** `false`
  - **Requires restart:** Yes

- **`context.fileFiltering.enableRecursiveFileSearch`** (boolean):

  - **Description:** Enable recursive file search functionality when completing
    @ references in the prompt.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`context.fileFiltering.enableFuzzySearch`** (boolean):

  - **Description:** Enable fuzzy search when searching for files.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`context.fileFiltering.customIgnoreFilePaths`** (array):
  - **Description:** Additional ignore file paths to respect. These files take
    precedence over .geminiignore and .gitignore. Files earlier in the array
    take precedence over files later in the array, e.g. the first file takes
    precedence over the second one.
  - **Default:** `[]`
  - **Requires restart:** Yes

#### `tools`

- **`tools.sandbox`** (string):

  - **Description:** Legacy full-process sandbox execution environment. Set to a
    boolean to enable or disable the sandbox, provide a string path to a sandbox
    profile, or specify an explicit sandbox command (e.g., "docker", "podman",
    "lxc", "windows-native").
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`tools.sandboxAllowedPaths`** (array):

  - **Description:** List of additional paths that the sandbox is allowed to
    access.
  - **Default:** `[]`
  - **Requires restart:** Yes

- **`tools.sandboxNetworkAccess`** (boolean):

  - **Description:** Whether the sandbox is allowed to access the network.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`tools.shell.enableInteractiveShell`** (boolean):

  - **Description:** Use node-pty for an interactive shell experience. Fallback
    to child_process still applies.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`tools.shell.backgroundCompletionBehavior`** (enum):

  - **Description:** Controls what happens when a background shell command
    finishes. 'silent' (default): quietly exits in background. 'inject':
    automatically returns output to agent. 'notify': shows brief message in
    chat.
  - **Default:** `"silent"`
  - **Values:** `"silent"`, `"inject"`, `"notify"`

- **`tools.shell.pager`** (string):

  - **Description:** The pager command to use for shell output. Defaults to
    `cat`.
  - **Default:** `"cat"`

- **`tools.shell.showColor`** (boolean):

  - **Description:** Show color in shell output.
  - **Default:** `true`

- **`tools.shell.inactivityTimeout`** (number):

  - **Description:** The maximum time in seconds allowed without output from the
    shell command. Defaults to 5 minutes.
  - **Default:** `300`

- **`tools.shell.enableShellOutputEfficiency`** (boolean):

  - **Description:** Enable shell output efficiency optimizations for better
    performance.
  - **Default:** `true`

- **`tools.core`** (array):

  - **Description:** Restrict the set of built-in tools with an allowlist. Match
    semantics mirror tools.allowed; see the built-in tools documentation for
    available names.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`tools.allowed`** (array):

  - **Description:** Tool names that bypass the confirmation dialog. Useful for
    trusted commands (for example ["run_shell_command(git)",
    "run_shell_command(npm test)"]). See shell tool command restrictions for
    matching details.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`tools.confirmationRequired`** (array):

  - **Description:** Tool names that always require user confirmation. Takes
    precedence over allowed tools and core tool allowlists.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`tools.exclude`** (array):

  - **Description:** Tool names to exclude from discovery.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`tools.discoveryCommand`** (string):

  - **Description:** Command to run for tool discovery.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`tools.callCommand`** (string):

  - **Description:** Defines a custom shell command for invoking discovered
    tools. The command must take the tool name as the first argument, read JSON
    arguments from stdin, and emit JSON results on stdout.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`tools.useRipgrep`** (boolean):

  - **Description:** Use ripgrep for file content search instead of the fallback
    implementation. Provides faster search performance.
  - **Default:** `true`

- **`tools.truncateToolOutputThreshold`** (number):

  - **Description:** Maximum characters to show when truncating large tool
    outputs. Set to 0 or negative to disable truncation.
  - **Default:** `40000`
  - **Requires restart:** Yes

- **`tools.disableLLMCorrection`** (boolean):
  - **Description:** Disable LLM-based error correction for edit tools. When
    enabled, tools will fail immediately if exact string matches are not found,
    instead of attempting to self-correct.
  - **Default:** `true`
  - **Requires restart:** Yes

#### `mcp`

- **`mcp.serverCommand`** (string):

  - **Description:** Command to start an MCP server.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`mcp.allowed`** (array):

  - **Description:** A list of MCP servers to allow.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`mcp.excluded`** (array):
  - **Description:** A list of MCP servers to exclude.
  - **Default:** `undefined`
  - **Requires restart:** Yes

#### `useWriteTodos`

- **`useWriteTodos`** (boolean):
  - **Description:** Enable the write_todos tool.
  - **Default:** `true`

#### `security`

- **`security.toolSandboxing`** (boolean):

  - **Description:** Tool-level sandboxing. Isolates individual tools instead of
    the entire CLI process.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`security.disableYoloMode`** (boolean):

  - **Description:** Disable YOLO mode, even if enabled by a flag.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`security.disableAlwaysAllow`** (boolean):

  - **Description:** Disable "Always allow" options in tool confirmation
    dialogs.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`security.enablePermanentToolApproval`** (boolean):

  - **Description:** Enable the "Allow for all future sessions" option in tool
    confirmation dialogs.
  - **Default:** `false`

- **`security.autoAddToPolicyByDefault`** (boolean):

  - **Description:** When enabled, the "Allow for all future sessions" option
    becomes the default choice for low-risk tools in trusted workspaces.
  - **Default:** `false`

- **`security.blockGitExtensions`** (boolean):

  - **Description:** Blocks installing and loading extensions from Git.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`security.allowedExtensions`** (array):

  - **Description:** List of Regex patterns for allowed extensions. If nonempty,
    only extensions that match the patterns in this list are allowed. Overrides
    the blockGitExtensions setting.
  - **Default:** `[]`
  - **Requires restart:** Yes

- **`security.folderTrust.enabled`** (boolean):

  - **Description:** Setting to track whether Folder trust is enabled.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`security.environmentVariableRedaction.allowed`** (array):

  - **Description:** Environment variables to always allow (bypass redaction).
  - **Default:** `[]`
  - **Requires restart:** Yes

- **`security.environmentVariableRedaction.blocked`** (array):

  - **Description:** Environment variables to always redact.
  - **Default:** `[]`
  - **Requires restart:** Yes

- **`security.environmentVariableRedaction.enabled`** (boolean):

  - **Description:** Enable redaction of environment variables that may contain
    secrets.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`security.auth.selectedType`** (string):

  - **Description:** The currently selected authentication type.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`security.auth.enforcedType`** (string):

  - **Description:** The required auth type. If this does not match the selected
    auth type, the user will be prompted to re-authenticate.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`security.auth.useExternal`** (boolean):

  - **Description:** Whether to use an external authentication flow.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`security.enableConseca`** (boolean):
  - **Description:** Enable the context-aware security checker. This feature
    uses an LLM to dynamically generate and enforce security policies for tool
    use based on your prompt, providing an additional layer of protection
    against unintended actions.
  - **Default:** `false`
  - **Requires restart:** Yes

#### `advanced`

- **`advanced.autoConfigureMemory`** (boolean):

  - **Description:** Automatically configure Node.js memory limits. Note:
    Because memory is allocated during the initial process boot, this setting is
    only read from the global user settings file and ignores workspace-level
    overrides.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`advanced.dnsResolutionOrder`** (string):

  - **Description:** The DNS resolution order.
  - **Default:** `undefined`
  - **Requires restart:** Yes

- **`advanced.excludedEnvVars`** (array):

  - **Description:** Environment variables to exclude from project context.
  - **Default:**

    ```json
    ["DEBUG", "DEBUG_MODE"]
    ```

- **`advanced.ignoreLocalEnv`** (boolean):

  - **Description:** Whether to ignore generic .env files in the project
    directory.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`advanced.bugCommand`** (object):
  - **Description:** Configuration for the bug report command.
  - **Default:** `undefined`

#### `experimental`

- **`experimental.gemma`** (boolean):

  - **Description:** Enable access to Gemma 4 models via Gemini API.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`experimental.voiceMode`** (boolean):

  - **Description:** Enable experimental voice dictation and commands (/voice,
    /voice model).
  - **Default:** `false`

- **`experimental.voice.activationMode`** (enum):

  - **Description:** How to trigger voice recording with the Space key.
  - **Default:** `"push-to-talk"`
  - **Values:** `"push-to-talk"`, `"toggle"`

- **`experimental.voice.backend`** (enum):

  - **Description:** The backend to use for voice transcription. Note: When
    using the Gemini Live backend, voice recordings are sent to Google Cloud for
    transcription.
  - **Default:** `"gemini-live"`
  - **Values:** `"gemini-live"`, `"whisper"`

- **`experimental.voice.whisperModel`** (enum):

  - **Description:** The Whisper model to use for local transcription.
  - **Default:** `"ggml-base.en.bin"`
  - **Values:** `"ggml-tiny.en.bin"`, `"ggml-base.en.bin"`,
    `"ggml-large-v3-turbo-q5_0.bin"`, `"ggml-large-v3-turbo-q8_0.bin"`

- **`experimental.voice.stopGracePeriodMs`** (number):

  - **Description:** How long to wait for final transcription after stopping
    recording.
  - **Default:** `4000`

- **`experimental.adk.agentSessionNoninteractiveEnabled`** (boolean):

  - **Description:** Enable non-interactive agent sessions.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.adk.agentSessionInteractiveEnabled`** (boolean):

  - **Description:** Enable the agent session implementation for the interactive
    CLI.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.adk.agentSessionSubagentEnabled`** (boolean):

  - **Description:** Route subagent invocations through the AgentSession
    protocol instead of legacy executors.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.enableAgents`** (boolean):

  - **Description:** Enable local and remote subagents.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`experimental.worktrees`** (boolean):

  - **Description:** Enable automated Git worktree management for parallel work.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.extensionManagement`** (boolean):

  - **Description:** Enable extension management features.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`experimental.extensionConfig`** (boolean):

  - **Description:** Enable requesting and fetching of extension settings.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`experimental.extensionRegistry`** (boolean):

  - **Description:** Enable extension registry explore UI.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.extensionRegistryURI`** (string):

  - **Description:** The URI (web URL or local file path) of the extension
    registry.
  - **Default:** `"https://geminicli.com/extensions.json"`
  - **Requires restart:** Yes

- **`experimental.extensionReloading`** (boolean):

  - **Description:** Enables extension loading/unloading within the CLI session.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.useOSC52Paste`** (boolean):

  - **Description:** Use OSC 52 for pasting. This may be more robust than the
    default system when using remote terminal sessions (if your terminal is
    configured to allow it).
  - **Default:** `false`

- **`experimental.useOSC52Copy`** (boolean):

  - **Description:** Use OSC 52 for copying. This may be more robust than the
    default system when using remote terminal sessions (if your terminal is
    configured to allow it).
  - **Default:** `false`

- **`experimental.taskTracker`** (boolean):

  - **Description:** Enable task tracker tools.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.modelSteering`** (boolean):

  - **Description:** Enable model steering (user hints) to guide the model
    during tool execution.
  - **Default:** `false`

- **`experimental.directWebFetch`** (boolean):

  - **Description:** Enable web fetch behavior that bypasses LLM summarization.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.dynamicModelConfiguration`** (boolean):

  - **Description:** Enable dynamic model configuration (definitions,
    resolutions, and chains) via settings.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.gemmaModelRouter.enabled`** (boolean):

  - **Description:** Enable the Gemma Model Router (experimental). Requires a
    local endpoint serving Gemma via the Gemini API using LiteRT-LM shim.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.gemmaModelRouter.autoStartServer`** (boolean):

  - **Description:** Automatically start the LiteRT-LM server when Gemini CLI
    starts and the Gemma router is enabled.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.gemmaModelRouter.binaryPath`** (string):

  - **Description:** Custom path to the LiteRT-LM binary. Leave empty to use the
    default location (~/.gemini/bin/litert/).
  - **Default:** `""`
  - **Requires restart:** Yes

- **`experimental.gemmaModelRouter.classifier.host`** (string):

  - **Description:** The host of the classifier.
  - **Default:** `"http://localhost:9379"`
  - **Requires restart:** Yes

- **`experimental.gemmaModelRouter.classifier.model`** (string):

  - **Description:** The model to use for the classifier. Only tested on
    `gemma3-1b-gpu-custom`.
  - **Default:** `"gemma3-1b-gpu-custom"`
  - **Requires restart:** Yes

- **`experimental.stressTestProfile`** (boolean):

  - **Description:** Significantly lowers token limits to force early garbage
    collection and distillation for testing purposes.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.autoMemory`** (boolean):

  - **Description:** Automatically extract memory patches and skills from past
    sessions in the background. Every change is written as a unified diff
    `.patch` file under `<projectMemoryDir>/.inbox/<kind>/` and held for review
    in /memory inbox; nothing is applied until you approve it.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.generalistProfile`** (boolean):

  - **Description:** Suitable for general coding and software development tasks.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.powerUserProfile`** (boolean):

  - **Description:** Less cache friendly version of the generalist profile.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.contextManagement`** (boolean):

  - **Description:** Enable logic for context management.
  - **Default:** `false`
  - **Requires restart:** Yes

- **`experimental.topicUpdateNarration`** (boolean):
  - **Description:** Deprecated: Use general.topicUpdateNarration instead.
  - **Default:** `false`

#### `skills`

- **`skills.enabled`** (boolean):

  - **Description:** Enable Agent Skills.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`skills.disabled`** (array):
  - **Description:** List of disabled skills.
  - **Default:** `[]`
  - **Requires restart:** Yes

#### `hooksConfig`

- **`hooksConfig.enabled`** (boolean):

  - **Description:** Canonical toggle for the hooks system. When disabled, no
    hooks will be executed.
  - **Default:** `true`
  - **Requires restart:** Yes

- **`hooksConfig.disabled`** (array):

  - **Description:** List of hook names (commands) that should be disabled.
    Hooks in this list will not execute even if configured.
  - **Default:** `[]`

- **`hooksConfig.notifications`** (boolean):
  - **Description:** Show visual indicators when hooks are executing.
  - **Default:** `true`

#### `hooks`

- **`hooks.BeforeTool`** (array):

  - **Description:** Hooks that execute before tool execution. Can intercept,
    validate, or modify tool calls.
  - **Default:** `[]`

- **`hooks.AfterTool`** (array):

  - **Description:** Hooks that execute after tool execution. Can process
    results, log outputs, or trigger follow-up actions.
  - **Default:** `[]`

- **`hooks.BeforeAgent`** (array):

  - **Description:** Hooks that execute before agent loop starts. Can set up
    context or initialize resources.
  - **Default:** `[]`

- **`hooks.AfterAgent`** (array):

  - **Description:** Hooks that execute after agent loop completes. Can perform
    cleanup or summarize results.
  - **Default:** `[]`

- **`hooks.Notification`** (array):

  - **Description:** Hooks that execute on notification events (errors,
    warnings, info). Can log or alert on specific conditions.
  - **Default:** `[]`

- **`hooks.SessionStart`** (array):

  - **Description:** Hooks that execute when a session starts. Can initialize
    session-specific resources or state.
  - **Default:** `[]`

- **`hooks.SessionEnd`** (array):

  - **Description:** Hooks that execute when a session ends. Can perform cleanup
    or persist session data.
  - **Default:** `[]`

- **`hooks.PreCompress`** (array):

  - **Description:** Hooks that execute before chat history compression. Can
    back up or analyze conversation before compression.
  - **Default:** `[]`

- **`hooks.BeforeModel`** (array):

  - **Description:** Hooks that execute before LLM requests. Can modify prompts,
    inject context, or control model parameters.
  - **Default:** `[]`

- **`hooks.AfterModel`** (array):

  - **Description:** Hooks that execute after LLM responses. Can process
    outputs, extract information, or log interactions.
  - **Default:** `[]`

- **`hooks.BeforeToolSelection`** (array):
  - **Description:** Hooks that execute before tool selection. Can filter or
    prioritize available tools dynamically.
  - **Default:** `[]`

#### `contextManagement`

- **`contextManagement.historyWindow.maxTokens`** (number):

  - **Description:** The number of tokens to allow before triggering
    compression.
  - **Default:** `150000`
  - **Requires restart:** Yes

- **`contextManagement.historyWindow.retainedTokens`** (number):

  - **Description:** The number of tokens to always retain.
  - **Default:** `40000`
  - **Requires restart:** Yes

- **`contextManagement.messageLimits.normalMaxTokens`** (number):

  - **Description:** The target number of tokens to budget for a normal
    conversation turn.
  - **Default:** `2500`
  - **Requires restart:** Yes

- **`contextManagement.messageLimits.retainedMaxTokens`** (number):

  - **Description:** The maximum number of tokens a single conversation turn can
    consume before truncation.
  - **Default:** `12000`
  - **Requires restart:** Yes

- **`contextManagement.messageLimits.normalizationHeadRatio`** (number):

  - **Description:** The ratio of tokens to retain from the beginning of a
    truncated message (0.0 to 1.0).
  - **Default:** `0.25`
  - **Requires restart:** Yes

- **`contextManagement.tools.distillation.maxOutputTokens`** (number):

  - **Description:** Maximum tokens to show to the model when truncating large
    tool outputs.
  - **Default:** `10000`
  - **Requires restart:** Yes

- **`contextManagement.tools.distillation.summarizationThresholdTokens`**
  (number):

  - **Description:** Threshold above which truncated tool outputs will be
    summarized by an LLM.
  - **Default:** `20000`
  - **Requires restart:** Yes

- **`contextManagement.tools.outputMasking.protectionThresholdTokens`**
  (number):

  - **Description:** Minimum number of tokens to protect from masking (most
    recent tool outputs).
  - **Default:** `50000`
  - **Requires restart:** Yes

- **`contextManagement.tools.outputMasking.minPrunableThresholdTokens`**
  (number):

  - **Description:** Minimum prunable tokens required to trigger a masking pass.
  - **Default:** `30000`
  - **Requires restart:** Yes

- **`contextManagement.tools.outputMasking.protectLatestTurn`** (boolean):
  - **Description:** Ensures the absolute latest turn is never masked,
    regardless of token count.
  - **Default:** `true`
  - **Requires restart:** Yes

#### `admin`

- **`admin.secureModeEnabled`** (boolean):

  - **Description:** If true, disallows YOLO mode and "Always allow" options
    from being used.
  - **Default:** `false`

- **`admin.extensions.enabled`** (boolean):

  - **Description:** If false, disallows extensions from being installed or
    used.
  - **Default:** `true`

- **`admin.mcp.enabled`** (boolean):

  - **Description:** If false, disallows MCP servers from being used.
  - **Default:** `true`

- **`admin.mcp.config`** (object):

  - **Description:** Admin-configured MCP servers (allowlist).
  - **Default:** `{}`

- **`admin.mcp.requiredConfig`** (object):

  - **Description:** Admin-required MCP servers that are always injected.
  - **Default:** `{}`

- **`admin.skills.enabled`** (boolean):
  - **Description:** If false, disallows agent skills from being used.
  - **Default:** `true`
  <!-- SETTINGS-AUTOGEN:END -->

#### `mcpServers`

Configures connections to one or more Model-Context Protocol (MCP) servers for
discovering and using custom tools. Gemini CLI attempts to connect to each
configured MCP server to discover available tools. Every discovered tool is
prepended with the `mcp_` prefix and its server alias to form a fully qualified
name (FQN) (for example, `mcp_serverAlias_actualToolName`) to avoid conflicts.
Note that the system might strip certain schema properties from MCP tool
definitions for compatibility. At least one of `command`, `url`, or `httpUrl`
must be provided. If multiple are specified, the order of precedence is
`httpUrl`, then `url`, then `command`.

<!-- prettier-ignore -->
> [!WARNING]
> Avoid using underscores (`_`) in your server aliases (for example, use
> `my-server` instead of `my_server`). The underlying policy engine parses Fully
> Qualified Names (`mcp_server_tool`) using the first underscore after the
> `mcp_` prefix. An underscore in your server alias will cause the parser to
> misidentify the server name, which can cause security policies to fail
> silently.

- **`mcpServers.<SERVER_NAME>`** (object): The server parameters for the named
  server.
  - `command` (string, optional): The command to execute to start the MCP server
    via standard I/O.
  - `args` (array of strings, optional): Arguments to pass to the command.
  - `env` (object, optional): Environment variables to set for the server
    process.
  - `cwd` (string, optional): The working directory in which to start the
    server.
  - `url` (string, optional): The URL of an MCP server that uses Server-Sent
    Events (SSE) for communication.
  - `httpUrl` (string, optional): The URL of an MCP server that uses streamable
    HTTP for communication.
  - `headers` (object, optional): A map of HTTP headers to send with requests to
    `url` or `httpUrl`.
  - `timeout` (number, optional): Timeout in milliseconds for requests to this
    MCP server.
  - `trust` (boolean, optional): Trust this server and bypass all tool call
    confirmations.
  - `description` (string, optional): A brief description of the server, which
    may be used for display purposes.
  - `includeTools` (array of strings, optional): List of tool names to include
    from this MCP server. When specified, only the tools listed here will be
    available from this server (allowlist behavior). If not specified, all tools
    from the server are enabled by default.
  - `excludeTools` (array of strings, optional): List of tool names to exclude
    from this MCP server. Tools listed here will not be available to the model,
    even if they are exposed by the server. **Note:** `excludeTools` takes
    precedence over `includeTools` - if a tool is in both lists, it will be
    excluded.

#### `telemetry`

Configures logging and metrics collection for Gemini CLI. For more information,
see [Telemetry](../cli/telemetry.md).

- **Properties:**
  - **`enabled`** (boolean): Whether or not telemetry is enabled.
  - **`traces`** (boolean): Whether detailed traces with large attributes (like
    tool outputs and file reads) are captured. Defaults to `false`.
  - **`target`** (string): The destination for collected telemetry. Supported
    values are `local` and `gcp`.
  - **`otlpEndpoint`** (string): The endpoint for the OTLP Exporter.
  - **`otlpProtocol`** (string): The protocol for the OTLP Exporter (`grpc` or
    `http`).
  - **`logPrompts`** (boolean): Whether or not to include the content of user
    prompts in the logs.
  - **`outfile`** (string): The file to write telemetry to when `target` is
    `local`.
  - **`useCollector`** (boolean): Whether to use an external OTLP collector.

### Example `settings.json`

Here is an example of a `settings.json` file with the nested structure, new as
of v0.3.0:

```json
{
  "general": {
    "vimMode": true,
    "preferredEditor": "code",
    "sessionRetention": {
      "enabled": true,
      "maxAge": "30d",
      "maxCount": 100
    }
  },
  "ui": {
    "theme": "GitHub",
    "hideBanner": true,
    "hideTips": false,
    "customWittyPhrases": [
      "You forget a thousand things every day. Make sure this is one of ’em",
      "Connecting to AGI"
    ]
  },
  "tools": {
    "sandbox": "docker",
    "discoveryCommand": "bin/get_tools",
    "callCommand": "bin/call_tool",
    "exclude": ["write_file"]
  },
  "mcpServers": {
    "mainServer": {
      "command": "bin/mcp_server.py"
    },
    "anotherServer": {
      "command": "node",
      "args": ["mcp_server.js", "--verbose"]
    }
  },
  "telemetry": {
    "enabled": true,
    "target": "local",
    "otlpEndpoint": "http://localhost:4317",
    "logPrompts": true
  },
  "privacy": {
    "usageStatisticsEnabled": true
  },
  "model": {
    "name": "gemini-1.5-pro-latest",
    "maxSessionTurns": 10,
    "summarizeToolOutput": {
      "run_shell_command": {
        "tokenBudget": 100
      }
    }
  },
  "context": {
    "fileName": ["CONTEXT.md", "GEMINI.md"],
    "includeDirectories": ["path/to/dir1", "~/path/to/dir2", "../path/to/dir3"],
    "loadFromIncludeDirectories": true,
    "fileFiltering": {
      "respectGitIgnore": false
    }
  },
  "advanced": {
    "excludedEnvVars": ["DEBUG", "DEBUG_MODE", "NODE_ENV"]
  }
}
```

## Shell history

The CLI keeps a history of shell commands you run. To avoid conflicts between
different projects, this history is stored in a project-specific directory
within your user's home folder.

- **Location:** `~/.gemini/tmp/<project_hash>/shell_history`
  - `<project_hash>` is a unique identifier generated from your project's root
    path.
  - The history is stored in a file named `shell_history`.

## Environment variables and `.env` files

Environment variables are a common way to configure applications, especially for
sensitive information like API keys or for settings that might change between
environments. For authentication setup, see the
[Authentication documentation](../get-started/authentication.mdx) which covers
all available authentication methods.

The CLI automatically loads environment variables from an `.env` file. The
loading order is:

1.  `.env` file in the current working directory.
2.  If not found, it searches upwards in parent directories until it finds an
    `.env` file or reaches the project root (identified by a `.git` folder) or
    the home directory.
3.  If still not found, it looks for `~/.env` (in the user's home directory).

**Environment variable exclusion:** Some environment variables (like `DEBUG` and
`DEBUG_MODE`) are automatically excluded from being loaded from project `.env`
files to prevent interference with gemini-cli behavior. Variables from
`.gemini/.env` files are never excluded. You can customize this behavior using
the `advanced.excludedEnvVars` setting in your `settings.json` file.

- **`GEMINI_API_KEY`**:
  - Your API key for the Gemini API.
  - One of several available
    [authentication methods](../get-started/authentication.mdx).
  - Set this in your shell profile (for example, `~/.bashrc`, `~/.zshrc`) or an
    `.env` file.
- **`GEMINI_MODEL`**:
  - Specifies the default Gemini model to use.
  - Overrides the hardcoded default
  - Example: `export GEMINI_MODEL="gemini-3-flash-preview"` (Windows PowerShell:
    `$env:GEMINI_MODEL="gemini-3-flash-preview"`)
- **`GEMINI_CLI_TRUST_WORKSPACE`**:
  - If set to `"true"`, trusts the current workspace for the duration of the
    session, bypassing the folder trust check.
  - Useful for headless environments (for example, CI/CD pipelines).
- **`GEMINI_CLI_TRUSTED_FOLDERS_PATH`**:
  - Overrides the default location for the `trustedFolders.json` file.
  - Useful if you want to store this configuration in a custom location instead
    of the default `~/.gemini/`.
- **`GEMINI_CLI_IDE_PID`**:
  - Manually specifies the PID of the IDE process to use for integration. This
    is useful when running Gemini CLI in a standalone terminal while still
    wanting to associate it with a specific IDE instance.
  - Overrides the automatic IDE detection logic.
- **`GEMINI_CLI_HOME`**:
  - Specifies the root directory for Gemini CLI's user-level configuration and
    storage.
  - By default, this is the user's system home directory. The CLI will create a
    `.gemini` folder inside this directory.
  - Useful for shared compute environments or keeping CLI state isolated.
  - Example: `export GEMINI_CLI_HOME="/path/to/user/config"` (Windows
    PowerShell: `$env:GEMINI_CLI_HOME="C:\path\to\user\config"`)
- **`GEMINI_CLI_SURFACE`**:
  - Specifies a custom label to include in the `User-Agent` header for API
    traffic reporting.
  - This is useful for tracking specific internal tools or distribution
    channels.
  - Example: `export GEMINI_CLI_SURFACE="my-custom-tool"` (Windows PowerShell:
    `$env:GEMINI_CLI_SURFACE="my-custom-tool"`)
- **`GOOGLE_API_KEY`**:
  - Your Google Cloud API key.
  - Required for using Vertex AI in express mode.
  - Ensure you have the necessary permissions.
  - Example: `export GOOGLE_API_KEY="YOUR_GOOGLE_API_KEY"` (Windows PowerShell:
    `$env:GOOGLE_API_KEY="YOUR_GOOGLE_API_KEY"`).
- **`GOOGLE_CLOUD_PROJECT`**:
  - Your Google Cloud Project ID.
  - Required for using Code Assist or Vertex AI.
  - If using Vertex AI, ensure you have the necessary permissions in this
    project.
  - **Cloud Shell note:** When running in a Cloud Shell environment, this
    variable defaults to a special project allocated for Cloud Shell users. If
    you have `GOOGLE_CLOUD_PROJECT` set in your global environment in Cloud
    Shell, it will be overridden by this default. To use a different project in
    Cloud Shell, you must define `GOOGLE_CLOUD_PROJECT` in a `.env` file.
  - Example: `export GOOGLE_CLOUD_PROJECT="YOUR_PROJECT_ID"` (Windows
    PowerShell: `$env:GOOGLE_CLOUD_PROJECT="YOUR_PROJECT_ID"`).
- **`GOOGLE_APPLICATION_CREDENTIALS`** (string):
  - **Description:** The path to your Google Application Credentials JSON file.
  - **Example:**
    `export GOOGLE_APPLICATION_CREDENTIALS="/path/to/your/credentials.json"`
    (Windows PowerShell:
    `$env:GOOGLE_APPLICATION_CREDENTIALS="C:\path\to\your\credentials.json"`)
- **`GOOGLE_GENAI_API_VERSION`**:
  - Specifies the API version to use for Gemini API requests.
  - When set, overrides the default API version used by the SDK.
  - Example: `export GOOGLE_GENAI_API_VERSION="v1"` (Windows PowerShell:
    `$env:GOOGLE_GENAI_API_VERSION="v1"`)
- **`GOOGLE_GEMINI_BASE_URL`**:
  - Overrides the default base URL for Gemini API requests (when using
    `gemini-api-key` authentication).
  - Must be a valid URL. For security, it must use HTTPS unless pointing to
    `localhost` (or `127.0.0.1` / `[::1]`).
  - Example: `export GOOGLE_GEMINI_BASE_URL="https://my-proxy.com"` (Windows
    PowerShell: `$env:GOOGLE_GEMINI_BASE_URL="https://my-proxy.com"`)
- **`GOOGLE_VERTEX_BASE_URL`**:
  - Overrides the default base URL for Vertex AI API requests (when using
    `vertex-ai` authentication).
  - Must be a valid URL. For security, it must use HTTPS unless pointing to
    `localhost` (or `127.0.0.1` / `[::1]`).
  - Example: `export GOOGLE_VERTEX_BASE_URL="https://my-vertex-proxy.com"`
    (Windows PowerShell:
    `$env:GOOGLE_VERTEX_BASE_URL="https://my-vertex-proxy.com"`)
- **`OTLP_GOOGLE_CLOUD_PROJECT`**:
  - Your Google Cloud Project ID for Telemetry in Google Cloud
  - Example: `export OTLP_GOOGLE_CLOUD_PROJECT="YOUR_PROJECT_ID"` (Windows
    PowerShell: `$env:OTLP_GOOGLE_CLOUD_PROJECT="YOUR_PROJECT_ID"`).
- **`GEMINI_TELEMETRY_ENABLED`**:
  - Set to `true` or `1` to enable telemetry. Any other value is treated as
    disabling it.
  - Overrides the `telemetry.enabled` setting.
- **`GEMINI_TELEMETRY_TRACES_ENABLED`**:
  - Set to `true` or `1` to enable detailed tracing with large attributes. Any
    other value is treated as disabling it.
  - Overrides the `telemetry.traces` setting.
- **`GEMINI_TELEMETRY_TARGET`**:
  - Sets the telemetry target (`local` or `gcp`).
  - Overrides the `telemetry.target` setting.
- **`GEMINI_TELEMETRY_OTLP_ENDPOINT`**:
  - Sets the OTLP endpoint for telemetry.
  - Overrides the `telemetry.otlpEndpoint` setting.
- **`GEMINI_TELEMETRY_OTLP_PROTOCOL`**:
  - Sets the OTLP protocol (`grpc` or `http`).
  - Overrides the `telemetry.otlpProtocol` setting.
- **`GEMINI_TELEMETRY_LOG_PROMPTS`**:
  - Set to `true` or `1` to enable or disable logging of user prompts. Any other
    value is treated as disabling it.
  - Overrides the `telemetry.logPrompts` setting.
- **`GEMINI_TELEMETRY_OUTFILE`**:
  - Sets the file path to write telemetry to when the target is `local`.
  - Overrides the `telemetry.outfile` setting.
- **`GEMINI_TELEMETRY_USE_COLLECTOR`**:
  - Set to `true` or `1` to enable or disable using an external OTLP collector.
    Any other value is treated as disabling it.
  - Overrides the `telemetry.useCollector` setting.
- **`GOOGLE_CLOUD_LOCATION`**:
  - Your Google Cloud Project Location (for example, us-central1).
  - Required for using Vertex AI in non-express mode.
  - Example: `export GOOGLE_CLOUD_LOCATION="YOUR_PROJECT_LOCATION"` (Windows
    PowerShell: `$env:GOOGLE_CLOUD_LOCATION="YOUR_PROJECT_LOCATION"`).
- **`GEMINI_SANDBOX`**:
  - Alternative to the `sandbox` setting in `settings.json`.
  - Accepts `true`, `false`, `docker`, `podman`, or a custom command string.
- **`GEMINI_SYSTEM_MD`**:
  - Replaces the built‑in system prompt with content from a Markdown file.
  - `true`/`1`: Use project default path `./.gemini/system.md`.
  - Any other string: Treat as a path (relative/absolute supported, `~`
    expands).
  - `false`/`0` or unset: Use the built‑in prompt. See
    [System Prompt Override](../cli/system-prompt.md).
- **`GEMINI_WRITE_SYSTEM_MD`**:
  - Writes the current built‑in system prompt to a file for review.
  - `true`/`1`: Write to `./.gemini/system.md`. Otherwise treat the value as a
    path.
  - Run the CLI once with this set to generate the file.
- **`SEATBELT_PROFILE`** (macOS specific):
  - Switches the Seatbelt (`sandbox-exec`) profile on macOS.
  - `permissive-open`: (Default) Denies operations by default, confining writes
    to the project folder (and a few other folders, see
    `packages/cli/src/utils/sandbox-macos-permissive-open.sb`) while allowing
    broad file reads and network access.
  - `restrictive-open`: Declines operations by default, allows network.
  - `strict-open`: Restricts both reads and writes to the working directory,
    allows network.
  - `strict-proxied`: Same as `strict-open` but routes network through proxy.
  - `<profile_name>`: Uses a custom profile. To define a custom profile, create
    a file named `sandbox-macos-<profile_name>.sb` in your project's `.gemini/`
    directory (for example, `my-project/.gemini/sandbox-macos-custom.sb`).
- **`DEBUG` or `DEBUG_MODE`** (often used by underlying libraries or the CLI
  itself):
  - Set to `true` or `1` to enable verbose debug logging, which can be helpful
    for troubleshooting.
  - **Note:** These variables are automatically excluded from project `.env`
    files by default to prevent interference with gemini-cli behavior. Use
    `.gemini/.env` files if you need to set these for gemini-cli specifically.
- **`NO_COLOR`**:
  - Set to any value to disable all color output in the CLI.
- **`CLI_TITLE`**:
  - Set to a string to customize the title of the CLI.
- **`CODE_ASSIST_ENDPOINT`**:
  - Specifies the endpoint for the code assist server.
  - This is useful for development and testing.

### Environment variable redaction

To prevent accidental leakage of sensitive information, Gemini CLI automatically
redacts potential secrets from environment variables when executing tools (such
as shell commands). This "best effort" redaction applies to variables inherited
from the system or loaded from `.env` files.

**Default Redaction Rules:**

- **By Name:** Variables are redacted if their names contain sensitive terms
  like `TOKEN`, `SECRET`, `PASSWORD`, `KEY`, `AUTH`, `CREDENTIAL`, `PRIVATE`, or
  `CERT`.
- **By Value:** Variables are redacted if their values match known secret
  patterns, such as:
  - Private keys (RSA, OpenSSH, PGP, etc.)
  - Certificates
  - URLs containing credentials
  - API keys and tokens (GitHub, Google, AWS, Stripe, Slack, etc.)
- **Specific Blocklist:** Certain variables like `CLIENT_ID`, `DB_URI`,
  `DATABASE_URL`, and `CONNECTION_STRING` are always redacted by default.

**Allowlist (Never Redacted):**

- Common system variables (for example, `PATH`, `HOME`, `USER`, `SHELL`, `TERM`,
  `LANG`).
- Variables starting with `GEMINI_CLI_`.
- GitHub Action specific variables.

**Configuration:**

You can customize this behavior in your `settings.json` file:

- **`security.allowedEnvironmentVariables`**: A list of variable names to
  _never_ redact, even if they match sensitive patterns.
- **`security.blockedEnvironmentVariables`**: A list of variable names to
  _always_ redact, even if they don't match sensitive patterns.

```json
{
  "security": {
    "allowedEnvironmentVariables": ["MY_PUBLIC_KEY", "NOT_A_SECRET_TOKEN"],
    "blockedEnvironmentVariables": ["INTERNAL_IP_ADDRESS"]
  }
}
```

## Command-line arguments

Arguments passed directly when running the CLI can override other configurations
for that specific session.

- **`--acp`**:
  - Starts the agent in Agent Communication Protocol (ACP) mode.
- **`--allowed-mcp-server-names`**:
  - A comma-separated list of MCP server names to allow for the session.
- **`--allowed-tools <tool1,tool2,...>`**:
  - A comma-separated list of tool names that will bypass the confirmation
    dialog.
  - Example: `gemini --allowed-tools "ShellTool(git status)"`
- **`--approval-mode <mode>`**:
  - Sets the approval mode for tool calls. Available modes:
    - `default`: Prompt for approval on each tool call (default behavior)
    - `auto_edit`: Automatically approve edit tools (replace, write_file) while
      prompting for others
    - `yolo`: Automatically approve all tool calls (equivalent to `--yolo`)
    - `plan`: Read-only mode for tool calls (requires experimental planning to
      be enabled).
      > **Note:** This mode is currently under development and not yet fully
      > functional.
  - Cannot be used together with `--yolo`. Use `--approval-mode=yolo` instead of
    `--yolo` for the new unified approach.
  - Example: `gemini --approval-mode auto_edit`
- **`--debug`** (**`-d`**):
  - Enables debug mode for this session, providing more verbose output. Open the
    debug console with F12 to see the additional logging.
- **`--delete-session <identifier>`**:
  - Delete a specific chat session by its index number or full session UUID.
  - Use `--list-sessions` first to see available sessions, their indices, and
    UUIDs.
  - Example: `gemini --delete-session 3` or
    `gemini --delete-session a1b2c3d4-e5f6-7890-abcd-ef1234567890`
- **`--extensions <extension_name ...>`** (**`-e <extension_name ...>`**):
  - Specifies a list of extensions to use for the session. If not provided, all
    available extensions are used.
  - Use the special term `gemini -e none` to disable all extensions.
  - Example: `gemini -e my-extension -e my-other-extension`
- **`--fake-responses`**:
  - Path to a file with fake model responses for testing.
- **`--help`** (or **`-h`**):
  - Displays help information about command-line arguments.
- **`--include-directories <dir1,dir2,...>`**:
  - Includes additional directories in the workspace for multi-directory
    support.
  - Can be specified multiple times or as comma-separated values.
  - 5 directories can be added at maximum.
  - Example: `--include-directories /path/to/project1,/path/to/project2` or
    `--include-directories /path/to/project1 --include-directories /path/to/project2`
- **`--list-extensions`** (**`-l`**):
  - Lists all available extensions and exits.
- **`--list-sessions`**:
  - List all available chat sessions for the current project and exit.
  - Shows session indices, dates, message counts, and preview of first user
    message.
  - Example: `gemini --list-sessions`
- **`--model <model_name>`** (**`-m <model_name>`**):
  - Specifies the Gemini model to use for this session.
  - Example: `npm start -- --model gemini-3-pro-preview`
- **`--output-format <format>`**:
  - **Description:** Specifies the format of the CLI output for non-interactive
    mode.
  - **Values:**
    - `text`: (Default) The standard human-readable output.
    - `json`: A machine-readable JSON output.
    - `stream-json`: A streaming JSON output that emits real-time events.
  - **Note:** For structured output and scripting, use the
    `--output-format json` or `--output-format stream-json` flag.
- **`--prompt <your_prompt>`** (**`-p <your_prompt>`**):
  - Used to pass a prompt directly to the command. This invokes Gemini CLI in a
    non-interactive mode.
- **`--prompt-interactive <your_prompt>`** (**`-i <your_prompt>`**):
  - Starts an interactive session with the provided prompt as the initial input.
  - The prompt is processed within the interactive session, not before it.
  - Cannot be used when piping input from stdin.
  - Example: `gemini -i "explain this code"`
- **`--record-responses`**:
  - Path to a file to record model responses for testing.
- **`--resume [session_id]`** (**`-r [session_id]`**):
  - Resume a previous chat session. Use "latest" for the most recent session,
    provide a session index number, or provide a full session UUID.
  - If no session_id is provided, defaults to "latest".
  - Example: `gemini --resume 5` or `gemini --resume latest` or
    `gemini --resume a1b2c3d4-e5f6-7890-abcd-ef1234567890` or `gemini --resume`
  - See [Session Management](../cli/session-management.md) for more details.
- **`--sandbox`** (**`-s`**):
  - Enables sandbox mode for this session.
- **`--screen-reader`**:
  - Enables screen reader mode, which adjusts the TUI for better compatibility
    with screen readers.
- **`--version`**:
  - Displays the version of the CLI.
- **`--yolo`**:
  - Enables YOLO mode, which automatically approves all tool calls.

## Context files (hierarchical instructional context)

While not strictly configuration for the CLI's _behavior_, context files
(defaulting to `GEMINI.md` but configurable via the `context.fileName` setting)
are crucial for configuring the _instructional context_ (also referred to as
"memory") provided to the Gemini model. This powerful feature lets you give
project-specific instructions, coding style guides, or any relevant background
information to the AI, making its responses more tailored and accurate to your
needs. The CLI includes UI elements, such as an indicator in the footer showing
the number of loaded context files, to keep you informed about the active
context.

- **Purpose:** These Markdown files contain instructions, guidelines, or context
  that you want the Gemini model to be aware of during your interactions. The
  system is designed to manage this instructional context hierarchically.

### Example context file content (for example, `GEMINI.md`)

Here's a conceptual example of what a context file at the root of a TypeScript
project might contain:

```markdown
# Project: My Awesome TypeScript Library

## General Instructions:

- When generating new TypeScript code, follow the existing coding style.
- Ensure all new functions and classes have JSDoc comments.
- Prefer functional programming paradigms where appropriate.
- All code should be compatible with TypeScript 5.0 and Node.js 20+.

## Coding Style:

- Use 2 spaces for indentation.
- Interface names should be prefixed with `I` (for example, `IUserService`).
- Private class members should be prefixed with an underscore (`_`).
- Always use strict equality (`===` and `!==`).

## Specific Component: `src/api/client.ts`

- This file handles all outbound API requests.
- When adding new API call functions, ensure they include robust error handling
  and logging.
- Use the existing `fetchWithRetry` utility for all GET requests.

## Regarding Dependencies:

- Avoid introducing new external dependencies unless absolutely necessary.
- If a new dependency is required, state the reason.
```

This example demonstrates how you can provide general project context, specific
coding conventions, and even notes about particular files or components. The
more relevant and precise your context files are, the better the AI can assist
you. Project-specific context files are highly encouraged to establish
conventions and context.

- **Hierarchical loading and precedence:** The CLI implements a sophisticated
  hierarchical memory system by loading context files (for example, `GEMINI.md`)
  from several locations. Content from files lower in this list (more specific)
  typically overrides or supplements content from files higher up (more
  general). The exact concatenation order and final context can be inspected
  using the `/memory show` command. The typical loading order is:
  1.  **Global context file:**
      - Location: `~/.gemini/<configured-context-filename>` (for example,
        `~/.gemini/GEMINI.md` in your user home directory).
      - Scope: Provides default instructions for all your projects.
  2.  **Project root and ancestors context files:**
      - Location: The CLI searches for the configured context file in the
        current working directory and then in each parent directory up to either
        the project root (identified by a `.git` folder) or your home directory.
      - Scope: Provides context relevant to the entire project or a significant
        portion of it.
  3.  **Sub-directory context files (contextual/local):**
      - Location: The CLI also scans for the configured context file in
        subdirectories _below_ the current working directory (respecting common
        ignore patterns like `node_modules`, `.git`, etc.). The breadth of this
        search is limited to 200 directories by default, but can be configured
        with the `context.discoveryMaxDirs` setting in your `settings.json`
        file.
      - Scope: Allows for highly specific instructions relevant to a particular
        component, module, or subsection of your project.
- **Concatenation and UI indication:** The contents of all found context files
  are concatenated (with separators indicating their origin and path) and
  provided as part of the system prompt to the Gemini model. The CLI footer
  displays the count of loaded context files, giving you a quick visual cue
  about the active instructional context.
- **Importing content:** You can modularize your context files by importing
  other Markdown files using the `@path/to/file.md` syntax. For more details,
  see the [Memory Import Processor documentation](./memport.md).
- **Commands for memory management:**
  - Use `/memory refresh` to force a re-scan and reload of all context files
    from all configured locations. This updates the AI's instructional context.
  - Use `/memory show` to display the combined instructional context currently
    loaded, allowing you to verify the hierarchy and content being used by the
    AI.
  - See the [Commands documentation](./commands.md#memory) for full details on
    the `/memory` command and its sub-commands (`show` and `reload`).

By understanding and utilizing these configuration layers and the hierarchical
nature of context files, you can effectively manage the AI's memory and tailor
Gemini CLI's responses to your specific needs and projects.

## Sandboxing

Gemini CLI can execute potentially unsafe operations (like shell commands and
file modifications) within a sandboxed environment to protect your system.

Sandboxing is disabled by default, but you can enable it in a few ways:

- Using `--sandbox` or `-s` flag.
- Setting `GEMINI_SANDBOX` environment variable.
- Sandbox is enabled when using `--yolo` or `--approval-mode=yolo` by default.

By default, it uses a pre-built `gemini-cli-sandbox` Docker image.

For project-specific sandboxing needs, you can create a custom Dockerfile at
`.gemini/sandbox.Dockerfile` in your project's root directory. This Dockerfile
can be based on the base sandbox image:

```dockerfile
FROM gemini-cli-sandbox

# Add your custom dependencies or configurations here.
# Note: The base image runs as the non-root 'node' user.
# You must switch to 'root' to install system packages.
# For example:
# USER root
# RUN apt-get update && apt-get install -y some-package
# USER node
# COPY ./my-config /app/my-config
```

When `.gemini/sandbox.Dockerfile` exists, you can use `BUILD_SANDBOX`
environment variable when running Gemini CLI to automatically build the custom
sandbox image:

```bash
BUILD_SANDBOX=1 gemini -s
```

Building a custom sandbox with `BUILD_SANDBOX` is only supported when running
Gemini CLI from source. If you installed the CLI with npm, build the Docker
image separately and reference that image in your sandbox configuration.

## Usage statistics

To help us improve Gemini CLI, we collect anonymized usage statistics. This data
helps us understand how the CLI is used, identify common issues, and prioritize
new features.

**What we collect:**

- **Tool calls:** We log the names of the tools that are called, whether they
  succeed or fail, and how long they take to execute. We do not collect the
  arguments passed to the tools or any data returned by them.
- **API requests:** We log the Gemini model used for each request, the duration
  of the request, and whether it was successful. We do not collect the content
  of the prompts or responses.
- **Session information:** We collect information about the configuration of the
  CLI, such as the enabled tools and the approval mode.

**What we DON'T collect:**

- **Personally identifiable information (PII):** We do not collect any personal
  information, such as your name, email address, or API keys.
- **Prompt and response content:** We do not log the content of your prompts or
  the responses from the Gemini model.
- **File content:** We do not log the content of any files that are read or
  written by the CLI.

**How to opt out:**

You can opt out of usage statistics collection at any time by setting the
`usageStatisticsEnabled` property to `false` under the `privacy` category in
your `settings.json` file:

```json
{
  "privacy": {
    "usageStatisticsEnabled": false
  }
}
```