1# Configuring Zed
2
3Zed is designed to be configured: we want to fit your workflow and preferences exactly. We provide default settings that are designed to be a comfortable starting point for as many people as possible, but we hope you will enjoy tweaking it to make it feel incredible.
4
5In addition to the settings described here, you may also want to change your [theme](./themes.md), configure your [key bindings](./key-bindings.md), set up [tasks](./tasks.md) or install [extensions](https://github.com/zed-industries/extensions).
6
7## Settings files
8
9<!--
10TBD: Settings files. Rewrite with "remote settings" in mind (e.g. `local settings` on the remote host).
11Consider renaming `zed: Open Local Settings` to `zed: Open Project Settings`.
12
13TBD: Add settings documentation about how settings are merged as overlays. E.g. project>local>default. Note how settings that are maps are merged, but settings that are arrays are replaced and must include the defaults.
14-->
15
16Your settings file can be opened with {#kb zed::OpenSettings}. By default it is located at `~/.config/zed/settings.json`, though if you have XDG_CONFIG_HOME in your environment on Linux it will be at `$XDG_CONFIG_HOME/zed/settings.json` instead.
17
18This configuration is merged with any local configuration inside your projects. You can open the project settings by running {#action zed::OpenProjectSettings} from the command palette. This will create a `.zed` directory containing`.zed/settings.json`.
19
20Although most projects will only need one settings file at the root, you can add more local settings files for subdirectories as needed. Not all settings can be set in local files, just those that impact the behavior of the editor and language tooling. For example you can set `tab_size`, `formatter` etc. but not `theme`, `vim_mode` and similar.
21
22The syntax for configuration files is a super-set of JSON that allows `//` comments.
23
24## Default settings
25
26You can find the default settings for your current Zed by running {#action zed::OpenDefaultSettings} from the command palette.
27
28Extensions that provide language servers may also provide default settings for those language servers.
29
30# Settings
31
32## Active Pane Modifiers
33
34- Description: Styling settings applied to the active pane.
35- Setting: `active_pane_modifiers`
36- Default:
37
38```json
39{
40 "active_pane_modifiers": {
41 "border_size": 0.0,
42 "inactive_opacity": 1.0
43 }
44}
45```
46
47### Border size
48
49- Description: Size of the border surrounding the active pane. When set to 0, the active pane doesn't have any border. The border is drawn inset.
50- Setting: `border_size`
51- Default: `0.0`
52
53**Options**
54
55Non-negative `float` values
56
57### Inactive Opacity
58
59- Description: Opacity of inactive panels. When set to 1.0, the inactive panes have the same opacity as the active one. If set to 0, the inactive panes content will not be visible at all. Values are clamped to the [0.0, 1.0] range.
60- Setting: `inactive_opacity`
61- Default: `1.0`
62
63**Options**
64
65`float` values
66
67## Bottom Dock Layout
68
69- Description: Control the layout of the bottom dock, relative to the left and right docks
70- Setting: `bottom_dock_layout`
71- Default: `"contained"`
72
73**Options**
74
751. Contain the bottom dock, giving the full height of the window to the left and right docks
76
77```json
78{
79 "bottom_dock_layout": "contained"
80}
81```
82
832. Give the bottom dock the full width of the window, truncating the left and right docks
84
85```json
86{
87 "bottom_dock_layout": "full"
88}
89```
90
913. Left align the bottom dock, truncating the left dock and giving the right dock the full height of the window
92
93```json
94{
95 "bottom_dock_layout": "left_aligned"
96}
97```
98
993. Right align the bottom dock, giving the left dock the full height of the window and truncating the right dock.
100
101```json
102{
103 "bottom_dock_layout": "right_aligned"
104}
105```
106
107## Auto Install extensions
108
109- Description: Define extensions to be autoinstalled or never be installed.
110- Setting: `auto_install_extension`
111- Default: `{ "html": true }`
112
113**Options**
114
115You can find the names of your currently installed extensions by listing the subfolders under the [extension installation location](./extensions/installing-extensions.md#installation-location):
116
117On MacOS:
118
119```sh
120ls ~/Library/Application\ Support/Zed/extensions/installed/
121```
122
123On Linux:
124
125```sh
126ls ~/.local/share/zed/extensions/installed
127```
128
129Define extensions which should be installed (`true`) or never installed (`false`).
130
131```json
132{
133 "auto_install_extensions": {
134 "html": true,
135 "dockerfile": true,
136 "docker-compose": false
137 }
138}
139```
140
141## Autosave
142
143- Description: When to automatically save edited buffers.
144- Setting: `autosave`
145- Default: `off`
146
147**Options**
148
1491. To disable autosave, set it to `off`:
150
151```json
152{
153 "autosave": "off"
154}
155```
156
1572. To autosave when focus changes, use `on_focus_change`:
158
159```json
160{
161 "autosave": "on_focus_change"
162}
163```
164
1653. To autosave when the active window changes, use `on_window_change`:
166
167```json
168{
169 "autosave": "on_window_change"
170}
171```
172
1734. To autosave after an inactivity period, use `after_delay`:
174
175```json
176{
177 "autosave": {
178 "after_delay": {
179 "milliseconds": 1000
180 }
181 }
182}
183```
184
185## Restore on Startup
186
187- Description: Controls session restoration on startup.
188- Setting: `restore_on_startup`
189- Default: `last_session`
190
191**Options**
192
1931. Restore all workspaces that were open when quitting Zed:
194
195```json
196{
197 "restore_on_startup": "last_session"
198}
199```
200
2012. Restore the workspace that was closed last:
202
203```json
204{
205 "restore_on_startup": "last_workspace"
206}
207```
208
2093. Always start with an empty editor:
210
211```json
212{
213 "restore_on_startup": "none"
214}
215```
216
217## Autoscroll on Clicks
218
219- Description: Whether to scroll when clicking near the edge of the visible text area.
220- Setting: `autoscroll_on_clicks`
221- Default: `false`
222
223**Options**
224
225`boolean` values
226
227## Auto Update
228
229- Description: Whether or not to automatically check for updates.
230- Setting: `auto_update`
231- Default: `true`
232
233**Options**
234
235`boolean` values
236
237## Base Keymap
238
239- Description: Base key bindings scheme. Base keymaps can be overridden with user keymaps.
240- Setting: `base_keymap`
241- Default: `VSCode`
242
243**Options**
244
2451. VSCode
246
247```json
248{
249 "base_keymap": "VSCode"
250}
251```
252
2532. Atom
254
255```json
256{
257 "base_keymap": "Atom"
258}
259```
260
2613. JetBrains
262
263```json
264{
265 "base_keymap": "JetBrains"
266}
267```
268
2694. None
270
271```json
272{
273 "base_keymap": "None"
274}
275```
276
2775. SublimeText
278
279```json
280{
281 "base_keymap": "SublimeText"
282}
283```
284
2856. TextMate
286
287```json
288{
289 "base_keymap": "TextMate"
290}
291```
292
293## Buffer Font Family
294
295- Description: The name of a font to use for rendering text in the editor.
296- Setting: `buffer_font_family`
297- Default: `.ZedMono`. This currently aliases to [Lilex](https://lilex.myrt.co).
298
299**Options**
300
301The name of any font family installed on the user's system, or `".ZedMono"`.
302
303## Buffer Font Features
304
305- Description: The OpenType features to enable for text in the editor.
306- Setting: `buffer_font_features`
307- Default: `null`
308- Platform: macOS and Windows.
309
310**Options**
311
312Zed supports all OpenType features that can be enabled or disabled for a given buffer or terminal font, as well as setting values for font features.
313
314For example, to disable font ligatures, add the following to your settings:
315
316```json
317{
318 "buffer_font_features": {
319 "calt": false
320 }
321}
322```
323
324You can also set other OpenType features, like setting `cv01` to `7`:
325
326```json
327{
328 "buffer_font_features": {
329 "cv01": 7
330 }
331}
332```
333
334## Buffer Font Fallbacks
335
336- Description: Set the buffer text's font fallbacks, this will be merged with the platform's default fallbacks.
337- Setting: `buffer_font_fallbacks`
338- Default: `null`
339- Platform: macOS and Windows.
340
341**Options**
342
343For example, to use `Nerd Font` as a fallback, add the following to your settings:
344
345```json
346{
347 "buffer_font_fallbacks": ["Nerd Font"]
348}
349```
350
351## Buffer Font Size
352
353- Description: The default font size for text in the editor.
354- Setting: `buffer_font_size`
355- Default: `15`
356
357**Options**
358
359`integer` values from `6` to `100` pixels (inclusive)
360
361## Buffer Font Weight
362
363- Description: The default font weight for text in the editor.
364- Setting: `buffer_font_weight`
365- Default: `400`
366
367**Options**
368
369`integer` values between `100` and `900`
370
371## Buffer Line Height
372
373- Description: The default line height for text in the editor.
374- Setting: `buffer_line_height`
375- Default: `"comfortable"`
376
377**Options**
378
379`"standard"`, `"comfortable"` or `{ "custom": float }` (`1` is compact, `2` is loose)
380
381## Close on File Delete
382
383- Description: Whether to automatically close editor tabs when their corresponding files are deleted from disk.
384- Setting: `close_on_file_delete`
385- Default: `false`
386
387**Options**
388
389`boolean` values
390
391When enabled, this setting will automatically close tabs for files that have been deleted from the file system. This is particularly useful for workflows involving temporary or scratch files that are frequently created and deleted. When disabled (default), deleted files remain open with a strikethrough through their tab title.
392
393Note: Dirty files (files with unsaved changes) will not be automatically closed even when this setting is enabled, ensuring you don't lose unsaved work.
394
395## Confirm Quit
396
397- Description: Whether or not to prompt the user to confirm before closing the application.
398- Setting: `confirm_quit`
399- Default: `false`
400
401**Options**
402
403`boolean` values
404
405## Centered Layout
406
407- Description: Configuration for the centered layout mode.
408- Setting: `centered_layout`
409- Default:
410
411```json
412"centered_layout": {
413 "left_padding": 0.2,
414 "right_padding": 0.2,
415}
416```
417
418**Options**
419
420The `left_padding` and `right_padding` options define the relative width of the
421left and right padding of the central pane from the workspace when the centered layout mode is activated. Valid values range is from `0` to `0.4`.
422
423## Direnv Integration
424
425- Description: Settings for [direnv](https://direnv.net/) integration. Requires `direnv` to be installed.
426 `direnv` integration make it possible to use the environment variables set by a `direnv` configuration to detect some language servers in `$PATH` instead of installing them.
427 It also allows for those environment variables to be used in tasks.
428- Setting: `load_direnv`
429- Default: `"direct"`
430
431**Options**
432
433There are two options to choose from:
434
4351. `shell_hook`: Use the shell hook to load direnv. This relies on direnv to activate upon entering the directory. Supports POSIX shells and fish.
4362. `direct`: Use `direnv export json` to load direnv. This will load direnv directly without relying on the shell hook and might cause some inconsistencies. This allows direnv to work with any shell.
437
438## Edit Predictions
439
440- Description: Settings for edit predictions.
441- Setting: `edit_predictions`
442- Default:
443
444```json
445 "edit_predictions": {
446 "disabled_globs": [
447 "**/.env*",
448 "**/*.pem",
449 "**/*.key",
450 "**/*.cert",
451 "**/*.crt",
452 "**/.dev.vars",
453 "**/secrets.yml"
454 ]
455 }
456```
457
458**Options**
459
460### Disabled Globs
461
462- Description: A list of globs for which edit predictions should be disabled for. This list adds to a pre-existing, sensible default set of globs. Any additional ones you add are combined with them.
463- Setting: `disabled_globs`
464- Default: `["**/.env*", "**/*.pem", "**/*.key", "**/*.cert", "**/*.crt", "**/.dev.vars", "**/secrets.yml"]`
465
466**Options**
467
468List of `string` values.
469
470## Edit Predictions Disabled in
471
472- Description: A list of language scopes in which edit predictions should be disabled.
473- Setting: `edit_predictions_disabled_in`
474- Default: `[]`
475
476**Options**
477
478List of `string` values
479
4801. Don't show edit predictions in comments:
481
482```json
483"disabled_in": ["comment"]
484```
485
4862. Don't show edit predictions in strings and comments:
487
488```json
489"disabled_in": ["comment", "string"]
490```
491
4923. Only in Go, don't show edit predictions in strings and comments:
493
494```json
495{
496 "languages": {
497 "Go": {
498 "edit_predictions_disabled_in": ["comment", "string"]
499 }
500 }
501}
502```
503
504## Current Line Highlight
505
506- Description: How to highlight the current line in the editor.
507- Setting: `current_line_highlight`
508- Default: `all`
509
510**Options**
511
5121. Don't highlight the current line:
513
514```json
515"current_line_highlight": "none"
516```
517
5182. Highlight the gutter area:
519
520```json
521"current_line_highlight": "gutter"
522```
523
5243. Highlight the editor area:
525
526```json
527"current_line_highlight": "line"
528```
529
5304. Highlight the full line:
531
532```json
533"current_line_highlight": "all"
534```
535
536## Selection Highlight
537
538- Description: Whether to highlight all occurrences of the selected text in an editor.
539- Setting: `selection_highlight`
540- Default: `true`
541
542## LSP Highlight Debounce
543
544- Description: The debounce delay before querying highlights from the language server based on the current cursor location.
545- Setting: `lsp_highlight_debounce`
546- Default: `75`
547
548## Cursor Blink
549
550- Description: Whether or not the cursor blinks.
551- Setting: `cursor_blink`
552- Default: `true`
553
554**Options**
555
556`boolean` values
557
558## Cursor Shape
559
560- Description: Cursor shape for the default editor.
561- Setting: `cursor_shape`
562- Default: `bar`
563
564**Options**
565
5661. A vertical bar:
567
568```json
569"cursor_shape": "bar"
570```
571
5722. A block that surrounds the following character:
573
574```json
575"cursor_shape": "block"
576```
577
5783. An underline / underscore that runs along the following character:
579
580```json
581"cursor_shape": "underline"
582```
583
5844. An box drawn around the following character:
585
586```json
587"cursor_shape": "hollow"
588```
589
590## Hide Mouse
591
592- Description: Determines when the mouse cursor should be hidden in an editor or input box.
593- Setting: `hide_mouse`
594- Default: `on_typing_and_movement`
595
596**Options**
597
5981. Never hide the mouse cursor:
599
600```json
601"hide_mouse": "never"
602```
603
6042. Hide only when typing:
605
606```json
607"hide_mouse": "on_typing"
608```
609
6103. Hide on both typing and cursor movement:
611
612```json
613"hide_mouse": "on_typing_and_movement"
614```
615
616## Snippet Sort Order
617
618- Description: Determines how snippets are sorted relative to other completion items.
619- Setting: `snippet_sort_order`
620- Default: `inline`
621
622**Options**
623
6241. Place snippets at the top of the completion list:
625
626```json
627"snippet_sort_order": "top"
628```
629
6302. Place snippets normally without any preference:
631
632```json
633"snippet_sort_order": "inline"
634```
635
6363. Place snippets at the bottom of the completion list:
637
638```json
639"snippet_sort_order": "bottom"
640```
641
6424. Do not show snippets in the completion list at all:
643
644```json
645"snippet_sort_order": "none"
646```
647
648## Editor Scrollbar
649
650- Description: Whether or not to show the editor scrollbar and various elements in it.
651- Setting: `scrollbar`
652- Default:
653
654```json
655"scrollbar": {
656 "show": "auto",
657 "cursors": true,
658 "git_diff": true,
659 "search_results": true,
660 "selected_text": true,
661 "selected_symbol": true,
662 "diagnostics": "all",
663 "axes": {
664 "horizontal": true,
665 "vertical": true,
666 },
667},
668```
669
670### Show Mode
671
672- Description: When to show the editor scrollbar.
673- Setting: `show`
674- Default: `auto`
675
676**Options**
677
6781. Show the scrollbar if there's important information or follow the system's configured behavior:
679
680```json
681"scrollbar": {
682 "show": "auto"
683}
684```
685
6862. Match the system's configured behavior:
687
688```json
689"scrollbar": {
690 "show": "system"
691}
692```
693
6943. Always show the scrollbar:
695
696```json
697"scrollbar": {
698 "show": "always"
699}
700```
701
7024. Never show the scrollbar:
703
704```json
705"scrollbar": {
706 "show": "never"
707}
708```
709
710### Cursor Indicators
711
712- Description: Whether to show cursor positions in the scrollbar.
713- Setting: `cursors`
714- Default: `true`
715
716**Options**
717
718`boolean` values
719
720### Git Diff Indicators
721
722- Description: Whether to show git diff indicators in the scrollbar.
723- Setting: `git_diff`
724- Default: `true`
725
726**Options**
727
728`boolean` values
729
730### Search Results Indicators
731
732- Description: Whether to show buffer search results in the scrollbar.
733- Setting: `search_results`
734- Default: `true`
735
736**Options**
737
738`boolean` values
739
740### Selected Text Indicators
741
742- Description: Whether to show selected text occurrences in the scrollbar.
743- Setting: `selected_text`
744- Default: `true`
745
746**Options**
747
748`boolean` values
749
750### Selected Symbols Indicators
751
752- Description: Whether to show selected symbol occurrences in the scrollbar.
753- Setting: `selected_symbol`
754- Default: `true`
755
756**Options**
757
758`boolean` values
759
760### Diagnostics
761
762- Description: Which diagnostic indicators to show in the scrollbar.
763- Setting: `diagnostics`
764- Default: `all`
765
766**Options**
767
7681. Show all diagnostics:
769
770```json
771{
772 "diagnostics": "all"
773}
774```
775
7762. Do not show any diagnostics:
777
778```json
779{
780 "diagnostics": "none"
781}
782```
783
7843. Show only errors:
785
786```json
787{
788 "diagnostics": "error"
789}
790```
791
7924. Show only errors and warnings:
793
794```json
795{
796 "diagnostics": "warning"
797}
798```
799
8005. Show only errors, warnings, and information:
801
802```json
803{
804 "diagnostics": "information"
805}
806```
807
808### Axes
809
810- Description: Forcefully enable or disable the scrollbar for each axis
811- Setting: `axes`
812- Default:
813
814```json
815"scrollbar": {
816 "axes": {
817 "horizontal": true,
818 "vertical": true,
819 },
820}
821```
822
823#### Horizontal
824
825- Description: When false, forcefully disables the horizontal scrollbar. Otherwise, obey other settings.
826- Setting: `horizontal`
827- Default: `true`
828
829**Options**
830
831`boolean` values
832
833#### Vertical
834
835- Description: When false, forcefully disables the vertical scrollbar. Otherwise, obey other settings.
836- Setting: `vertical`
837- Default: `true`
838
839**Options**
840
841`boolean` values
842
843## Minimap
844
845- Description: Settings related to the editor's minimap, which provides an overview of your document.
846- Setting: `minimap`
847- Default:
848
849```json
850{
851 "minimap": {
852 "show": "never",
853 "thumb": "always",
854 "thumb_border": "left_open",
855 "current_line_highlight": null
856 }
857}
858```
859
860### Show Mode
861
862- Description: When to show the minimap in the editor.
863- Setting: `show`
864- Default: `never`
865
866**Options**
867
8681. Always show the minimap:
869
870```json
871{
872 "show": "always"
873}
874```
875
8762. Show the minimap if the editor's scrollbars are visible:
877
878```json
879{
880 "show": "auto"
881}
882```
883
8843. Never show the minimap:
885
886```json
887{
888 "show": "never"
889}
890```
891
892### Thumb Display
893
894- Description: When to show the minimap thumb (the visible editor area) in the minimap.
895- Setting: `thumb`
896- Default: `always`
897
898**Options**
899
9001. Show the minimap thumb when hovering over the minimap:
901
902```json
903{
904 "thumb": "hover"
905}
906```
907
9082. Always show the minimap thumb:
909
910```json
911{
912 "thumb": "always"
913}
914```
915
916### Thumb Border
917
918- Description: How the minimap thumb border should look.
919- Setting: `thumb_border`
920- Default: `left_open`
921
922**Options**
923
9241. Display a border on all sides of the thumb:
925
926```json
927{
928 "thumb_border": "full"
929}
930```
931
9322. Display a border on all sides except the left side:
933
934```json
935{
936 "thumb_border": "left_open"
937}
938```
939
9403. Display a border on all sides except the right side:
941
942```json
943{
944 "thumb_border": "right_open"
945}
946```
947
9484. Display a border only on the left side:
949
950```json
951{
952 "thumb_border": "left_only"
953}
954```
955
9565. Display the thumb without any border:
957
958```json
959{
960 "thumb_border": "none"
961}
962```
963
964### Current Line Highlight
965
966- Description: How to highlight the current line in the minimap.
967- Setting: `current_line_highlight`
968- Default: `null`
969
970**Options**
971
9721. Inherit the editor's current line highlight setting:
973
974```json
975{
976 "minimap": {
977 "current_line_highlight": null
978 }
979}
980```
981
9822. Highlight the current line in the minimap:
983
984```json
985{
986 "minimap": {
987 "current_line_highlight": "line"
988 }
989}
990```
991
992or
993
994```json
995{
996 "minimap": {
997 "current_line_highlight": "all"
998 }
999}
1000```
1001
10023. Do not highlight the current line in the minimap:
1003
1004```json
1005{
1006 "minimap": {
1007 "current_line_highlight": "gutter"
1008 }
1009}
1010```
1011
1012or
1013
1014```json
1015{
1016 "minimap": {
1017 "current_line_highlight": "none"
1018 }
1019}
1020```
1021
1022## Editor Tab Bar
1023
1024- Description: Settings related to the editor's tab bar.
1025- Settings: `tab_bar`
1026- Default:
1027
1028```json
1029"tab_bar": {
1030 "show": true,
1031 "show_nav_history_buttons": true,
1032 "show_tab_bar_buttons": true
1033}
1034```
1035
1036### Show
1037
1038- Description: Whether or not to show the tab bar in the editor.
1039- Setting: `show`
1040- Default: `true`
1041
1042**Options**
1043
1044`boolean` values
1045
1046### Navigation History Buttons
1047
1048- Description: Whether or not to show the navigation history buttons.
1049- Setting: `show_nav_history_buttons`
1050- Default: `true`
1051
1052**Options**
1053
1054`boolean` values
1055
1056### Tab Bar Buttons
1057
1058- Description: Whether or not to show the tab bar buttons.
1059- Setting: `show_tab_bar_buttons`
1060- Default: `true`
1061
1062**Options**
1063
1064`boolean` values
1065
1066## Editor Tabs
1067
1068- Description: Configuration for the editor tabs.
1069- Setting: `tabs`
1070- Default:
1071
1072```json
1073"tabs": {
1074 "close_position": "right",
1075 "file_icons": false,
1076 "git_status": false,
1077 "activate_on_close": "history",
1078 "show_close_button": "hover",
1079 "show_diagnostics": "off"
1080},
1081```
1082
1083### Close Position
1084
1085- Description: Where to display close button within a tab.
1086- Setting: `close_position`
1087- Default: `right`
1088
1089**Options**
1090
10911. Display the close button on the right:
1092
1093```json
1094{
1095 "close_position": "right"
1096}
1097```
1098
10992. Display the close button on the left:
1100
1101```json
1102{
1103 "close_position": "left"
1104}
1105```
1106
1107### File Icons
1108
1109- Description: Whether to show the file icon for a tab.
1110- Setting: `file_icons`
1111- Default: `false`
1112
1113### Git Status
1114
1115- Description: Whether or not to show Git file status in tab.
1116- Setting: `git_status`
1117- Default: `false`
1118
1119### Activate on close
1120
1121- Description: What to do after closing the current tab.
1122- Setting: `activate_on_close`
1123- Default: `history`
1124
1125**Options**
1126
11271. Activate the tab that was open previously:
1128
1129```json
1130{
1131 "activate_on_close": "history"
1132}
1133```
1134
11352. Activate the right neighbour tab if present:
1136
1137```json
1138{
1139 "activate_on_close": "neighbour"
1140}
1141```
1142
11433. Activate the left neighbour tab if present:
1144
1145```json
1146{
1147 "activate_on_close": "left_neighbour"
1148}
1149```
1150
1151### Show close button
1152
1153- Description: Controls the appearance behavior of the tab's close button.
1154- Setting: `show_close_button`
1155- Default: `hover`
1156
1157**Options**
1158
11591. Show it just upon hovering the tab:
1160
1161```json
1162{
1163 "show_close_button": "hover"
1164}
1165```
1166
11672. Show it persistently:
1168
1169```json
1170{
1171 "show_close_button": "always"
1172}
1173```
1174
11753. Never show it, even if hovering it:
1176
1177```json
1178{
1179 "show_close_button": "hidden"
1180}
1181```
1182
1183### Show Diagnostics
1184
1185- Description: Whether to show diagnostics indicators in tabs. This setting only works when file icons are active and controls which files with diagnostic issues to mark.
1186- Setting: `show_diagnostics`
1187- Default: `off`
1188
1189**Options**
1190
11911. Do not mark any files:
1192
1193```json
1194{
1195 "show_diagnostics": "off"
1196}
1197```
1198
11992. Only mark files with errors:
1200
1201```json
1202{
1203 "show_diagnostics": "errors"
1204}
1205```
1206
12073. Mark files with errors and warnings:
1208
1209```json
1210{
1211 "show_diagnostics": "all"
1212}
1213```
1214
1215### Show Inline Code Actions
1216
1217- Description: Whether to show code action button at start of buffer line.
1218- Setting: `inline_code_actions`
1219- Default: `true`
1220
1221**Options**
1222
1223`boolean` values
1224
1225### Drag And Drop Selection
1226
1227- Description: Whether to allow drag and drop text selection in buffer. `delay` is the milliseconds that must elapse before drag and drop is allowed. Otherwise, a new text selection is created.
1228- Setting: `drag_and_drop_selection`
1229- Default:
1230
1231```json
1232"drag_and_drop_selection": {
1233 "enabled": true,
1234 "delay": 300
1235}
1236```
1237
1238## Editor Toolbar
1239
1240- Description: Whether or not to show various elements in the editor toolbar.
1241- Setting: `toolbar`
1242- Default:
1243
1244```json
1245"toolbar": {
1246 "breadcrumbs": true,
1247 "quick_actions": true,
1248 "selections_menu": true,
1249 "agent_review": true,
1250 "code_actions": false
1251},
1252```
1253
1254**Options**
1255
1256Each option controls displaying of a particular toolbar element. If all elements are hidden, the editor toolbar is not displayed.
1257
1258## Enable Language Server
1259
1260- Description: Whether or not to use language servers to provide code intelligence.
1261- Setting: `enable_language_server`
1262- Default: `true`
1263
1264**Options**
1265
1266`boolean` values
1267
1268## Ensure Final Newline On Save
1269
1270- Description: Removes any lines containing only whitespace at the end of the file and ensures just one newline at the end.
1271- Setting: `ensure_final_newline_on_save`
1272- Default: `true`
1273
1274**Options**
1275
1276`boolean` values
1277
1278## Status Bar
1279
1280- Description: Control various elements in the status bar. Note that some items in the status bar have their own settings set elsewhere.
1281- Setting: `status_bar`
1282- Default:
1283
1284```json
1285"status_bar": {
1286 "active_language_button": true,
1287},
1288```
1289
1290## LSP
1291
1292- Description: Configuration for language servers.
1293- Setting: `lsp`
1294- Default: `null`
1295
1296**Options**
1297
1298The following settings can be overridden for specific language servers:
1299
1300- `initialization_options`
1301- `settings`
1302
1303To override configuration for a language server, add an entry for that language server's name to the `lsp` value.
1304
1305Some options are passed via `initialization_options` to the language server. These are for options which must be specified at language server startup and when changed will require restarting the language server.
1306
1307For example to pass the `check` option to `rust-analyzer`, use the following configuration:
1308
1309```json
1310"lsp": {
1311 "rust-analyzer": {
1312 "initialization_options": {
1313 "check": {
1314 "command": "clippy" // rust-analyzer.check.command (default: "check")
1315 }
1316 }
1317 }
1318}
1319```
1320
1321While other options may be changed at a runtime and should be placed under `settings`:
1322
1323```json
1324"lsp": {
1325 "yaml-language-server": {
1326 "settings": {
1327 "yaml": {
1328 "keyOrdering": true // Enforces alphabetical ordering of keys in maps
1329 }
1330 }
1331 }
1332}
1333```
1334
1335## LSP Highlight Debounce
1336
1337- Description: The debounce delay in milliseconds before querying highlights from the language server based on the current cursor location.
1338- Setting: `lsp_highlight_debounce`
1339- Default: `75`
1340
1341**Options**
1342
1343`integer` values representing milliseconds
1344
1345## Format On Save
1346
1347- Description: Whether or not to perform a buffer format before saving.
1348- Setting: `format_on_save`
1349- Default: `on`
1350
1351**Options**
1352
13531. `on`, enables format on save obeying `formatter` setting:
1354
1355```json
1356{
1357 "format_on_save": "on"
1358}
1359```
1360
13612. `off`, disables format on save:
1362
1363```json
1364{
1365 "format_on_save": "off"
1366}
1367```
1368
1369## Formatter
1370
1371- Description: How to perform a buffer format.
1372- Setting: `formatter`
1373- Default: `auto`
1374
1375**Options**
1376
13771. To use the current language server, use `"language_server"`:
1378
1379```json
1380{
1381 "formatter": "language_server"
1382}
1383```
1384
13852. Or to use an external command, use `"external"`. Specify the name of the formatting program to run, and an array of arguments to pass to the program. The buffer's text will be passed to the program on stdin, and the formatted output should be written to stdout. For example, the following command would strip trailing spaces using [`sed(1)`](https://linux.die.net/man/1/sed):
1386
1387```json
1388{
1389 "formatter": {
1390 "external": {
1391 "command": "sed",
1392 "arguments": ["-e", "s/ *$//"]
1393 }
1394 }
1395}
1396```
1397
13983. External formatters may optionally include a `{buffer_path}` placeholder which at runtime will include the path of the buffer being formatted. Formatters operate by receiving file content via standard input, reformatting it and then outputting it to standard output and so normally don't know the filename of what they are formatting. Tools like Prettier support receiving the file path via a command line argument which can then used to impact formatting decisions.
1399
1400WARNING: `{buffer_path}` should not be used to direct your formatter to read from a filename. Your formatter should only read from standard input and should not read or write files directly.
1401
1402```json
1403 "formatter": {
1404 "external": {
1405 "command": "prettier",
1406 "arguments": ["--stdin-filepath", "{buffer_path}"]
1407 }
1408 }
1409```
1410
14114. Or to use code actions provided by the connected language servers, use `"code_actions"`:
1412
1413```json
1414{
1415 "formatter": {
1416 "code_actions": {
1417 // Use ESLint's --fix:
1418 "source.fixAll.eslint": true,
1419 // Organize imports on save:
1420 "source.organizeImports": true
1421 }
1422 }
1423}
1424```
1425
14265. Or to use multiple formatters consecutively, use an array of formatters:
1427
1428```json
1429{
1430 "formatter": [
1431 { "language_server": { "name": "rust-analyzer" } },
1432 {
1433 "external": {
1434 "command": "sed",
1435 "arguments": ["-e", "s/ *$//"]
1436 }
1437 }
1438 ]
1439}
1440```
1441
1442Here `rust-analyzer` will be used first to format the code, followed by a call of sed.
1443If any of the formatters fails, the subsequent ones will still be executed.
1444
1445## Code Actions On Format
1446
1447- Description: The code actions to perform with the primary language server when formatting the buffer.
1448- Setting: `code_actions_on_format`
1449- Default: `{}`, except for Go it's `{ "source.organizeImports": true }`
1450
1451**Examples**
1452
1453<!--
1454TBD: Add Python Ruff source.organizeImports example
1455-->
1456
14571. Organize imports on format in TypeScript and TSX buffers:
1458
1459```json
1460{
1461 "languages": {
1462 "TypeScript": {
1463 "code_actions_on_format": {
1464 "source.organizeImports": true
1465 }
1466 },
1467 "TSX": {
1468 "code_actions_on_format": {
1469 "source.organizeImports": true
1470 }
1471 }
1472 }
1473}
1474```
1475
14762. Run ESLint `fixAll` code action when formatting:
1477
1478```json
1479{
1480 "languages": {
1481 "JavaScript": {
1482 "code_actions_on_format": {
1483 "source.fixAll.eslint": true
1484 }
1485 }
1486 }
1487}
1488```
1489
14903. Run only a single ESLint rule when using `fixAll`:
1491
1492```json
1493{
1494 "languages": {
1495 "JavaScript": {
1496 "code_actions_on_format": {
1497 "source.fixAll.eslint": true
1498 }
1499 }
1500 },
1501 "lsp": {
1502 "eslint": {
1503 "settings": {
1504 "codeActionOnSave": {
1505 "rules": ["import/order"]
1506 }
1507 }
1508 }
1509 }
1510}
1511```
1512
1513## Auto close
1514
1515- Description: Whether to automatically add matching closing characters when typing opening parenthesis, bracket, brace, single or double quote characters.
1516- Setting: `use_autoclose`
1517- Default: `true`
1518
1519**Options**
1520
1521`boolean` values
1522
1523## Always Treat Brackets As Autoclosed
1524
1525- Description: Controls how the editor handles the autoclosed characters.
1526- Setting: `always_treat_brackets_as_autoclosed`
1527- Default: `false`
1528
1529**Options**
1530
1531`boolean` values
1532
1533**Example**
1534
1535If the setting is set to `true`:
1536
15371. Enter in the editor: `)))`
15382. Move the cursor to the start: `^)))`
15393. Enter again: `)))`
1540
1541The result is still `)))` and not `))))))`, which is what it would be by default.
1542
1543## File Scan Exclusions
1544
1545- Setting: `file_scan_exclusions`
1546- Description: Files or globs of files that will be excluded by Zed entirely. They will be skipped during file scans, file searches, and not be displayed in the project file tree. Overrides `file_scan_inclusions`.
1547- Default:
1548
1549```json
1550"file_scan_exclusions": [
1551 "**/.git",
1552 "**/.svn",
1553 "**/.hg",
1554 "**/.jj",
1555 "**/CVS",
1556 "**/.DS_Store",
1557 "**/Thumbs.db",
1558 "**/.classpath",
1559 "**/.settings"
1560],
1561```
1562
1563Note, specifying `file_scan_exclusions` in settings.json will override the defaults (shown above). If you are looking to exclude additional items you will need to include all the default values in your settings.
1564
1565## File Scan Inclusions
1566
1567- Setting: `file_scan_inclusions`
1568- Description: Files or globs of files that will be included by Zed, even when ignored by git. This is useful for files that are not tracked by git, but are still important to your project. Note that globs that are overly broad can slow down Zed's file scanning. `file_scan_exclusions` takes precedence over these inclusions.
1569- Default:
1570
1571```json
1572"file_scan_inclusions": [".env*"],
1573```
1574
1575## File Types
1576
1577- Setting: `file_types`
1578- Description: Configure how Zed selects a language for a file based on its filename or extension. Supports glob entries.
1579- Default:
1580
1581```json
1582"file_types": {
1583 "JSONC": ["**/.zed/**/*.json", "**/zed/**/*.json", "**/Zed/**/*.json", "**/.vscode/**/*.json"],
1584 "Shell Script": [".env.*"]
1585}
1586```
1587
1588**Examples**
1589
1590To interpret all `.c` files as C++, files called `MyLockFile` as TOML and files starting with `Dockerfile` as Dockerfile:
1591
1592```json
1593{
1594 "file_types": {
1595 "C++": ["c"],
1596 "TOML": ["MyLockFile"],
1597 "Dockerfile": ["Dockerfile*"]
1598 }
1599}
1600```
1601
1602## Diagnostics
1603
1604- Description: Configuration for diagnostics-related features.
1605- Setting: `diagnostics`
1606- Default:
1607
1608```json
1609{
1610 "diagnostics": {
1611 "include_warnings": true,
1612 "inline": {
1613 "enabled": false
1614 },
1615 "update_with_cursor": false,
1616 "primary_only": false,
1617 "use_rendered": false
1618 }
1619}
1620```
1621
1622### Inline Diagnostics
1623
1624- Description: Whether or not to show diagnostics information inline.
1625- Setting: `inline`
1626- Default:
1627
1628```json
1629{
1630 "diagnostics": {
1631 "inline": {
1632 "enabled": false,
1633 "update_debounce_ms": 150,
1634 "padding": 4,
1635 "min_column": 0,
1636 "max_severity": null
1637 }
1638 }
1639}
1640```
1641
1642**Options**
1643
16441. Enable inline diagnostics.
1645
1646```json
1647{
1648 "diagnostics": {
1649 "inline": {
1650 "enabled": true
1651 }
1652 }
1653}
1654```
1655
16562. Delay diagnostic updates until some time after the last diagnostic update.
1657
1658```json
1659{
1660 "diagnostics": {
1661 "inline": {
1662 "enabled": true,
1663 "update_debounce_ms": 150
1664 }
1665 }
1666}
1667```
1668
16693. Set padding between the end of the source line and the start of the diagnostic.
1670
1671```json
1672{
1673 "diagnostics": {
1674 "inline": {
1675 "enabled": true,
1676 "padding": 4
1677 }
1678 }
1679}
1680```
1681
16824. Horizontally align inline diagnostics at the given column.
1683
1684```json
1685{
1686 "diagnostics": {
1687 "inline": {
1688 "enabled": true,
1689 "min_column": 80
1690 }
1691 }
1692}
1693```
1694
16955. Show only warning and error diagnostics.
1696
1697```json
1698{
1699 "diagnostics": {
1700 "inline": {
1701 "enabled": true,
1702 "max_severity": "warning"
1703 }
1704 }
1705}
1706```
1707
1708## Git
1709
1710- Description: Configuration for git-related features.
1711- Setting: `git`
1712- Default:
1713
1714```json
1715{
1716 "git": {
1717 "git_gutter": "tracked_files",
1718 "inline_blame": {
1719 "enabled": true
1720 },
1721 "hunk_style": "staged_hollow"
1722 }
1723}
1724```
1725
1726### Git Gutter
1727
1728- Description: Whether or not to show the git gutter.
1729- Setting: `git_gutter`
1730- Default: `tracked_files`
1731
1732**Options**
1733
17341. Show git gutter in tracked files
1735
1736```json
1737{
1738 "git": {
1739 "git_gutter": "tracked_files"
1740 }
1741}
1742```
1743
17442. Hide git gutter
1745
1746```json
1747{
1748 "git": {
1749 "git_gutter": "hide"
1750 }
1751}
1752```
1753
1754### Gutter Debounce
1755
1756- Description: Sets the debounce threshold (in milliseconds) after which changes are reflected in the git gutter.
1757- Setting: `gutter_debounce`
1758- Default: `null`
1759
1760**Options**
1761
1762`integer` values representing milliseconds
1763
1764Example:
1765
1766```json
1767{
1768 "git": {
1769 "gutter_debounce": 100
1770 }
1771}
1772```
1773
1774### Inline Git Blame
1775
1776- Description: Whether or not to show git blame information inline, on the currently focused line.
1777- Setting: `inline_blame`
1778- Default:
1779
1780```json
1781{
1782 "git": {
1783 "inline_blame": {
1784 "enabled": true
1785 }
1786 }
1787}
1788```
1789
1790**Options**
1791
17921. Disable inline git blame:
1793
1794```json
1795{
1796 "git": {
1797 "inline_blame": {
1798 "enabled": false
1799 }
1800 }
1801}
1802```
1803
18042. Only show inline git blame after a delay (that starts after cursor stops moving):
1805
1806```json
1807{
1808 "git": {
1809 "inline_blame": {
1810 "delay_ms": 500
1811 }
1812 }
1813}
1814```
1815
18163. Show a commit summary next to the commit date and author:
1817
1818```json
1819{
1820 "git": {
1821 "inline_blame": {
1822 "show_commit_summary": true
1823 }
1824 }
1825}
1826```
1827
18284. Use this as the minimum column at which to display inline blame information:
1829
1830```json
1831{
1832 "git": {
1833 "inline_blame": {
1834 "min_column": 80
1835 }
1836 }
1837}
1838```
1839
18405. Set the padding between the end of the line and the inline blame hint, in ems:
1841
1842```json
1843{
1844 "git": {
1845 "inline_blame": {
1846 "padding": 10
1847 }
1848 }
1849}
1850```
1851
1852### Hunk Style
1853
1854- Description: What styling we should use for the diff hunks.
1855- Setting: `hunk_style`
1856- Default:
1857
1858```json
1859{
1860 "git": {
1861 "hunk_style": "staged_hollow"
1862 }
1863}
1864```
1865
1866**Options**
1867
18681. Show the staged hunks faded out and with a border:
1869
1870```json
1871{
1872 "git": {
1873 "hunk_style": "staged_hollow"
1874 }
1875}
1876```
1877
18782. Show unstaged hunks faded out and with a border:
1879
1880```json
1881{
1882 "git": {
1883 "hunk_style": "unstaged_hollow"
1884 }
1885}
1886```
1887
1888## Indent Guides
1889
1890- Description: Configuration related to indent guides. Indent guides can be configured separately for each language.
1891- Setting: `indent_guides`
1892- Default:
1893
1894```json
1895{
1896 "indent_guides": {
1897 "enabled": true,
1898 "line_width": 1,
1899 "active_line_width": 1,
1900 "coloring": "fixed",
1901 "background_coloring": "disabled"
1902 }
1903}
1904```
1905
1906**Options**
1907
19081. Disable indent guides
1909
1910```json
1911{
1912 "indent_guides": {
1913 "enabled": false
1914 }
1915}
1916```
1917
19182. Enable indent guides for a specific language.
1919
1920```json
1921{
1922 "languages": {
1923 "Python": {
1924 "indent_guides": {
1925 "enabled": true
1926 }
1927 }
1928 }
1929}
1930```
1931
19323. Enable indent aware coloring ("rainbow indentation").
1933 The colors that are used for different indentation levels are defined in the theme (theme key: `accents`). They can be customized by using theme overrides.
1934
1935```json
1936{
1937 "indent_guides": {
1938 "enabled": true,
1939 "coloring": "indent_aware"
1940 }
1941}
1942```
1943
19444. Enable indent aware background coloring ("rainbow indentation").
1945 The colors that are used for different indentation levels are defined in the theme (theme key: `accents`). They can be customized by using theme overrides.
1946
1947```json
1948{
1949 "indent_guides": {
1950 "enabled": true,
1951 "coloring": "indent_aware",
1952 "background_coloring": "indent_aware"
1953 }
1954}
1955```
1956
1957## Hard Tabs
1958
1959- Description: Whether to indent lines using tab characters or multiple spaces.
1960- Setting: `hard_tabs`
1961- Default: `false`
1962
1963**Options**
1964
1965`boolean` values
1966
1967## Multi Cursor Modifier
1968
1969- Description: Determines the modifier to be used to add multiple cursors with the mouse. The open hover link mouse gestures will adapt such that it do not conflict with the multicursor modifier.
1970- Setting: `multi_cursor_modifier`
1971- Default: `alt`
1972
1973**Options**
1974
19751. Maps to `Alt` on Linux and Windows and to `Option` on MacOS:
1976
1977```json
1978{
1979 "multi_cursor_modifier": "alt"
1980}
1981```
1982
19832. Maps `Control` on Linux and Windows and to `Command` on MacOS:
1984
1985```json
1986{
1987 "multi_cursor_modifier": "cmd_or_ctrl" // alias: "cmd", "ctrl"
1988}
1989```
1990
1991## Hover Popover Enabled
1992
1993- Description: Whether or not to show the informational hover box when moving the mouse over symbols in the editor.
1994- Setting: `hover_popover_enabled`
1995- Default: `true`
1996
1997**Options**
1998
1999`boolean` values
2000
2001## Hover Popover Delay
2002
2003- Description: Time to wait in milliseconds before showing the informational hover box.
2004- Setting: `hover_popover_delay`
2005- Default: `300`
2006
2007**Options**
2008
2009`integer` values representing milliseconds
2010
2011## Icon Theme
2012
2013- Description: The icon theme setting can be specified in two forms - either as the name of an icon theme or as an object containing the `mode`, `dark`, and `light` icon themes for files/folders inside Zed.
2014- Setting: `icon_theme`
2015- Default: `Zed (Default)`
2016
2017### Icon Theme Object
2018
2019- Description: Specify the icon theme using an object that includes the `mode`, `dark`, and `light`.
2020- Setting: `icon_theme`
2021- Default:
2022
2023```json
2024"icon_theme": {
2025 "mode": "system",
2026 "dark": "Zed (Default)",
2027 "light": "Zed (Default)"
2028},
2029```
2030
2031### Mode
2032
2033- Description: Specify the icon theme mode.
2034- Setting: `mode`
2035- Default: `system`
2036
2037**Options**
2038
20391. Set the icon theme to dark mode
2040
2041```json
2042{
2043 "mode": "dark"
2044}
2045```
2046
20472. Set the icon theme to light mode
2048
2049```json
2050{
2051 "mode": "light"
2052}
2053```
2054
20553. Set the icon theme to system mode
2056
2057```json
2058{
2059 "mode": "system"
2060}
2061```
2062
2063### Dark
2064
2065- Description: The name of the dark icon theme.
2066- Setting: `dark`
2067- Default: `Zed (Default)`
2068
2069**Options**
2070
2071Run the `icon theme selector: toggle` action in the command palette to see a current list of valid icon themes names.
2072
2073### Light
2074
2075- Description: The name of the light icon theme.
2076- Setting: `light`
2077- Default: `Zed (Default)`
2078
2079**Options**
2080
2081Run the `icon theme selector: toggle` action in the command palette to see a current list of valid icon themes names.
2082
2083## Inlay hints
2084
2085- Description: Configuration for displaying extra text with hints in the editor.
2086- Setting: `inlay_hints`
2087- Default:
2088
2089```json
2090"inlay_hints": {
2091 "enabled": false,
2092 "show_type_hints": true,
2093 "show_parameter_hints": true,
2094 "show_other_hints": true,
2095 "show_background": false,
2096 "edit_debounce_ms": 700,
2097 "scroll_debounce_ms": 50,
2098 "toggle_on_modifiers_press": null
2099}
2100```
2101
2102**Options**
2103
2104Inlay hints querying consists of two parts: editor (client) and LSP server.
2105With the inlay settings above are changed to enable the hints, editor will start to query certain types of hints and react on LSP hint refresh request from the server.
2106At this point, the server may or may not return hints depending on its implementation, further configuration might be needed, refer to the corresponding LSP server documentation.
2107
2108The following languages have inlay hints preconfigured by Zed:
2109
2110- [Go](https://docs.zed.dev/languages/go)
2111- [Rust](https://docs.zed.dev/languages/rust)
2112- [Svelte](https://docs.zed.dev/languages/svelte)
2113- [Typescript](https://docs.zed.dev/languages/typescript)
2114
2115Use the `lsp` section for the server configuration. Examples are provided in the corresponding language documentation.
2116
2117Hints are not instantly queried in Zed, two kinds of debounces are used, either may be set to 0 to be disabled.
2118Settings-related hint updates are not debounced.
2119
2120All possible config values for `toggle_on_modifiers_press` are:
2121
2122```json
2123"inlay_hints": {
2124 "toggle_on_modifiers_press": {
2125 "control": true,
2126 "shift": true,
2127 "alt": true,
2128 "platform": true,
2129 "function": true
2130 }
2131}
2132```
2133
2134Unspecified values have a `false` value, hints won't be toggled if all the modifiers are `false` or not all the modifiers are pressed.
2135
2136## Journal
2137
2138- Description: Configuration for the journal.
2139- Setting: `journal`
2140- Default:
2141
2142```json
2143"journal": {
2144 "path": "~",
2145 "hour_format": "hour12"
2146}
2147```
2148
2149### Path
2150
2151- Description: The path of the directory where journal entries are stored.
2152- Setting: `path`
2153- Default: `~`
2154
2155**Options**
2156
2157`string` values
2158
2159### Hour Format
2160
2161- Description: The format to use for displaying hours in the journal.
2162- Setting: `hour_format`
2163- Default: `hour12`
2164
2165**Options**
2166
21671. 12-hour format:
2168
2169```json
2170{
2171 "hour_format": "hour12"
2172}
2173```
2174
21752. 24-hour format:
2176
2177```json
2178{
2179 "hour_format": "hour24"
2180}
2181```
2182
2183## Languages
2184
2185- Description: Configuration for specific languages.
2186- Setting: `languages`
2187- Default: `null`
2188
2189**Options**
2190
2191To override settings for a language, add an entry for that languages name to the `languages` value. Example:
2192
2193```json
2194"languages": {
2195 "C": {
2196 "format_on_save": "off",
2197 "preferred_line_length": 64,
2198 "soft_wrap": "preferred_line_length"
2199 },
2200 "JSON": {
2201 "tab_size": 4
2202 }
2203}
2204```
2205
2206The following settings can be overridden for each specific language:
2207
2208- [`enable_language_server`](#enable-language-server)
2209- [`ensure_final_newline_on_save`](#ensure-final-newline-on-save)
2210- [`format_on_save`](#format-on-save)
2211- [`formatter`](#formatter)
2212- [`hard_tabs`](#hard-tabs)
2213- [`preferred_line_length`](#preferred-line-length)
2214- [`remove_trailing_whitespace_on_save`](#remove-trailing-whitespace-on-save)
2215- [`show_edit_predictions`](#show-edit-predictions)
2216- [`show_whitespaces`](#show-whitespaces)
2217- [`soft_wrap`](#soft-wrap)
2218- [`tab_size`](#tab-size)
2219- [`use_autoclose`](#use-autoclose)
2220- [`always_treat_brackets_as_autoclosed`](#always-treat-brackets-as-autoclosed)
2221
2222These values take in the same options as the root-level settings with the same name.
2223
2224## Network Proxy
2225
2226- Description: Configure a network proxy for Zed.
2227- Setting: `proxy`
2228- Default: `null`
2229
2230**Options**
2231
2232The proxy setting must contain a URL to the proxy.
2233
2234The following URI schemes are supported:
2235
2236- `http`
2237- `https`
2238- `socks4` - SOCKS4 proxy with local DNS
2239- `socks4a` - SOCKS4 proxy with remote DNS
2240- `socks5` - SOCKS5 proxy with local DNS
2241- `socks5h` - SOCKS5 proxy with remote DNS
2242
2243`http` will be used when no scheme is specified.
2244
2245By default no proxy will be used, or Zed will attempt to retrieve proxy settings from environment variables, such as `http_proxy`, `HTTP_PROXY`, `https_proxy`, `HTTPS_PROXY`, `all_proxy`, `ALL_PROXY`, `no_proxy` and `NO_PROXY`.
2246
2247For example, to set an `http` proxy, add the following to your settings:
2248
2249```json
2250{
2251 "proxy": "http://127.0.0.1:10809"
2252}
2253```
2254
2255Or to set a `socks5` proxy:
2256
2257```json
2258{
2259 "proxy": "socks5h://localhost:10808"
2260}
2261```
2262
2263If you wish to exclude certain hosts from using the proxy, set the `NO_PROXY` environment variable. This accepts a comma-separated list of hostnames, host suffixes, IPv4/IPv6 addresses or blocks that should not use the proxy. For example if your environment included `NO_PROXY="google.com, 192.168.1.0/24"` all hosts in `192.168.1.*`, `google.com` and `*.google.com` would bypass the proxy. See [reqwest NoProxy docs](https://docs.rs/reqwest/latest/reqwest/struct.NoProxy.html#method.from_string) for more.
2264
2265## Preview tabs
2266
2267- Description:
2268 Preview tabs allow you to open files in preview mode, where they close automatically when you switch to another file unless you explicitly pin them. This is useful for quickly viewing files without cluttering your workspace. Preview tabs display their file names in italics. \
2269 There are several ways to convert a preview tab into a regular tab:
2270
2271 - Double-clicking on the file
2272 - Double-clicking on the tab header
2273 - Using the `project_panel::OpenPermanent` action
2274 - Editing the file
2275 - Dragging the file to a different pane
2276
2277- Setting: `preview_tabs`
2278- Default:
2279
2280```json
2281"preview_tabs": {
2282 "enabled": true,
2283 "enable_preview_from_file_finder": false,
2284 "enable_preview_from_code_navigation": false,
2285}
2286```
2287
2288### Enable preview from file finder
2289
2290- Description: Determines whether to open files in preview mode when selected from the file finder.
2291- Setting: `enable_preview_from_file_finder`
2292- Default: `false`
2293
2294**Options**
2295
2296`boolean` values
2297
2298### Enable preview from code navigation
2299
2300- Description: Determines whether a preview tab gets replaced when code navigation is used to navigate away from the tab.
2301- Setting: `enable_preview_from_code_navigation`
2302- Default: `false`
2303
2304**Options**
2305
2306`boolean` values
2307
2308## File Finder
2309
2310### File Icons
2311
2312- Description: Whether to show file icons in the file finder.
2313- Setting: `file_icons`
2314- Default: `true`
2315
2316### Modal Max Width
2317
2318- Description: Max-width of the file finder modal. It can take one of these values: `small`, `medium`, `large`, `xlarge`, and `full`.
2319- Setting: `modal_max_width`
2320- Default: `small`
2321
2322### Skip Focus For Active In Search
2323
2324- Description: Determines whether the file finder should skip focus for the active file in search results.
2325- Setting: `skip_focus_for_active_in_search`
2326- Default: `true`
2327
2328## Preferred Line Length
2329
2330- Description: The column at which to soft-wrap lines, for buffers where soft-wrap is enabled.
2331- Setting: `preferred_line_length`
2332- Default: `80`
2333
2334**Options**
2335
2336`integer` values
2337
2338## Projects Online By Default
2339
2340- Description: Whether or not to show the online projects view by default.
2341- Setting: `projects_online_by_default`
2342- Default: `true`
2343
2344**Options**
2345
2346`boolean` values
2347
2348## Remove Trailing Whitespace On Save
2349
2350- Description: Whether or not to remove any trailing whitespace from lines of a buffer before saving it.
2351- Setting: `remove_trailing_whitespace_on_save`
2352- Default: `true`
2353
2354**Options**
2355
2356`boolean` values
2357
2358## Search
2359
2360- Description: Search options to enable by default when opening new project and buffer searches.
2361- Setting: `search`
2362- Default:
2363
2364```json
2365"search": {
2366 "whole_word": false,
2367 "case_sensitive": false,
2368 "include_ignored": false,
2369 "regex": false
2370},
2371```
2372
2373## Seed Search Query From Cursor
2374
2375- Description: When to populate a new search's query based on the text under the cursor.
2376- Setting: `seed_search_query_from_cursor`
2377- Default: `always`
2378
2379**Options**
2380
23811. `always` always populate the search query with the word under the cursor
23822. `selection` only populate the search query when there is text selected
23833. `never` never populate the search query
2384
2385## Use Smartcase Search
2386
2387- Description: When enabled, automatically adjusts search case sensitivity based on your query. If your search query contains any uppercase letters, the search becomes case-sensitive; if it contains only lowercase letters, the search becomes case-insensitive. \
2388 This applies to both in-file searches and project-wide searches.
2389- Setting: `use_smartcase_search`
2390- Default: `false`
2391
2392**Options**
2393
2394`boolean` values
2395
2396Examples:
2397
2398- Searching for "function" would match "function", "Function", "FUNCTION", etc.
2399- Searching for "Function" would only match "Function", not "function" or "FUNCTION"
2400
2401## Show Call Status Icon
2402
2403- Description: Whether or not to show the call status icon in the status bar.
2404- Setting: `show_call_status_icon`
2405- Default: `true`
2406
2407**Options**
2408
2409`boolean` values
2410
2411## Completions
2412
2413- Description: Controls how completions are processed for this language.
2414- Setting: `completions`
2415- Default:
2416
2417```json
2418{
2419 "completions": {
2420 "words": "fallback",
2421 "lsp": true,
2422 "lsp_fetch_timeout_ms": 0,
2423 "lsp_insert_mode": "replace_suffix"
2424 }
2425}
2426```
2427
2428### Words
2429
2430- Description: Controls how words are completed. For large documents, not all words may be fetched for completion.
2431- Setting: `words`
2432- Default: `fallback`
2433
2434**Options**
2435
24361. `enabled` - Always fetch document's words for completions along with LSP completions
24372. `fallback` - Only if LSP response errors or times out, use document's words to show completions
24383. `disabled` - Never fetch or complete document's words for completions (word-based completions can still be queried via a separate action)
2439
2440### LSP
2441
2442- Description: Whether to fetch LSP completions or not.
2443- Setting: `lsp`
2444- Default: `true`
2445
2446**Options**
2447
2448`boolean` values
2449
2450### LSP Fetch Timeout (ms)
2451
2452- Description: When fetching LSP completions, determines how long to wait for a response of a particular server. When set to 0, waits indefinitely.
2453- Setting: `lsp_fetch_timeout_ms`
2454- Default: `0`
2455
2456**Options**
2457
2458`integer` values representing milliseconds
2459
2460### LSP Insert Mode
2461
2462- Description: Controls what range to replace when accepting LSP completions.
2463- Setting: `lsp_insert_mode`
2464- Default: `replace_suffix`
2465
2466**Options**
2467
24681. `insert` - Replaces text before the cursor, using the `insert` range described in the LSP specification
24692. `replace` - Replaces text before and after the cursor, using the `replace` range described in the LSP specification
24703. `replace_subsequence` - Behaves like `"replace"` if the text that would be replaced is a subsequence of the completion text, and like `"insert"` otherwise
24714. `replace_suffix` - Behaves like `"replace"` if the text after the cursor is a suffix of the completion, and like `"insert"` otherwise
2472
2473## Show Completions On Input
2474
2475- Description: Whether or not to show completions as you type.
2476- Setting: `show_completions_on_input`
2477- Default: `true`
2478
2479**Options**
2480
2481`boolean` values
2482
2483## Show Completion Documentation
2484
2485- Description: Whether to display inline and alongside documentation for items in the completions menu.
2486- Setting: `show_completion_documentation`
2487- Default: `true`
2488
2489**Options**
2490
2491`boolean` values
2492
2493## Show Edit Predictions
2494
2495- Description: Whether to show edit predictions as you type or manually by triggering `editor::ShowEditPrediction`.
2496- Setting: `show_edit_predictions`
2497- Default: `true`
2498
2499**Options**
2500
2501`boolean` values
2502
2503## Show Whitespaces
2504
2505- Description: Whether or not to render whitespace characters in the editor.
2506- Setting: `show_whitespaces`
2507- Default: `selection`
2508
2509**Options**
2510
25111. `all`
25122. `selection`
25133. `none`
25144. `boundary`
2515
2516## Soft Wrap
2517
2518- Description: Whether or not to automatically wrap lines of text to fit editor / preferred width.
2519- Setting: `soft_wrap`
2520- Default: `none`
2521
2522**Options**
2523
25241. `none` to avoid wrapping generally, unless the line is too long
25252. `prefer_line` (deprecated, same as `none`)
25263. `editor_width` to wrap lines that overflow the editor width
25274. `preferred_line_length` to wrap lines that overflow `preferred_line_length` config value
25285. `bounded` to wrap lines at the minimum of `editor_width` and `preferred_line_length`
2529
2530## Wrap Guides (Vertical Rulers)
2531
2532- Description: Where to display vertical rulers as wrap-guides. Disable by setting `show_wrap_guides` to `false`.
2533- Setting: `wrap_guides`
2534- Default: []
2535
2536**Options**
2537
2538List of `integer` column numbers
2539
2540## Tab Size
2541
2542- Description: The number of spaces to use for each tab character.
2543- Setting: `tab_size`
2544- Default: `4`
2545
2546**Options**
2547
2548`integer` values
2549
2550## Telemetry
2551
2552- Description: Control what info is collected by Zed.
2553- Setting: `telemetry`
2554- Default:
2555
2556```json
2557"telemetry": {
2558 "diagnostics": true,
2559 "metrics": true
2560},
2561```
2562
2563**Options**
2564
2565### Diagnostics
2566
2567- Description: Setting for sending debug-related data, such as crash reports.
2568- Setting: `diagnostics`
2569- Default: `true`
2570
2571**Options**
2572
2573`boolean` values
2574
2575### Metrics
2576
2577- Description: Setting for sending anonymized usage data, such what languages you're using Zed with.
2578- Setting: `metrics`
2579- Default: `true`
2580
2581**Options**
2582
2583`boolean` values
2584
2585## Terminal
2586
2587- Description: Configuration for the terminal.
2588- Setting: `terminal`
2589- Default:
2590
2591```json
2592{
2593 "terminal": {
2594 "alternate_scroll": "off",
2595 "blinking": "terminal_controlled",
2596 "copy_on_select": false,
2597 "keep_selection_on_copy": false,
2598 "dock": "bottom",
2599 "default_width": 640,
2600 "default_height": 320,
2601 "detect_venv": {
2602 "on": {
2603 "directories": [".env", "env", ".venv", "venv"],
2604 "activate_script": "default"
2605 }
2606 },
2607 "env": {},
2608 "font_family": null,
2609 "font_features": null,
2610 "font_size": null,
2611 "line_height": "comfortable",
2612 "minimum_contrast": 45,
2613 "option_as_meta": false,
2614 "button": true,
2615 "shell": "system",
2616 "toolbar": {
2617 "breadcrumbs": true
2618 },
2619 "working_directory": "current_project_directory",
2620 "scrollbar": {
2621 "show": null
2622 }
2623 }
2624}
2625```
2626
2627### Terminal: Dock
2628
2629- Description: Control the position of the dock
2630- Setting: `dock`
2631- Default: `bottom`
2632
2633**Options**
2634
2635`"bottom"`, `"left"` or `"right"`
2636
2637### Terminal: Alternate Scroll
2638
2639- Description: Set whether Alternate Scroll mode (DECSET code: `?1007`) is active by default. Alternate Scroll mode converts mouse scroll events into up / down key presses when in the alternate screen (e.g. when running applications like vim or less). The terminal can still set and unset this mode with ANSI escape codes.
2640- Setting: `alternate_scroll`
2641- Default: `off`
2642
2643**Options**
2644
26451. Default alternate scroll mode to off
2646
2647```json
2648{
2649 "terminal": {
2650 "alternate_scroll": "off"
2651 }
2652}
2653```
2654
26552. Default alternate scroll mode to on
2656
2657```json
2658{
2659 "terminal": {
2660 "alternate_scroll": "on"
2661 }
2662}
2663```
2664
2665### Terminal: Blinking
2666
2667- Description: Set the cursor blinking behavior in the terminal
2668- Setting: `blinking`
2669- Default: `terminal_controlled`
2670
2671**Options**
2672
26731. Never blink the cursor, ignore the terminal mode
2674
2675```json
2676{
2677 "terminal": {
2678 "blinking": "off"
2679 }
2680}
2681```
2682
26832. Default the cursor blink to off, but allow the terminal to turn blinking on
2684
2685```json
2686{
2687 "terminal": {
2688 "blinking": "terminal_controlled"
2689 }
2690}
2691```
2692
26933. Always blink the cursor, ignore the terminal mode
2694
2695```json
2696{
2697 "terminal": {
2698 "blinking": "on"
2699 }
2700}
2701```
2702
2703### Terminal: Copy On Select
2704
2705- Description: Whether or not selecting text in the terminal will automatically copy to the system clipboard.
2706- Setting: `copy_on_select`
2707- Default: `false`
2708
2709**Options**
2710
2711`boolean` values
2712
2713**Example**
2714
2715```json
2716{
2717 "terminal": {
2718 "copy_on_select": true
2719 }
2720}
2721```
2722
2723### Terminal: Cursor Shape
2724
2725- Description: Whether or not selecting text in the terminal will automatically copy to the system clipboard.
2726- Setting: `cursor_shape`
2727- Default: `null` (defaults to block)
2728
2729**Options**
2730
27311. A block that surrounds the following character
2732
2733```json
2734{
2735 "terminal": {
2736 "cursor_shape": "block"
2737 }
2738}
2739```
2740
27412. A vertical bar
2742
2743```json
2744{
2745 "terminal": {
2746 "cursor_shape": "bar"
2747 }
2748}
2749```
2750
27513. An underline / underscore that runs along the following character
2752
2753```json
2754{
2755 "terminal": {
2756 "cursor_shape": "underline"
2757 }
2758}
2759```
2760
27614. A box drawn around the following character
2762
2763```json
2764{
2765 "terminal": {
2766 "cursor_shape": "hollow"
2767 }
2768}
2769```
2770
2771### Terminal: Keep Selection On Copy
2772
2773- Description: Whether or not to keep the selection in the terminal after copying text.
2774- Setting: `keep_selection_on_copy`
2775- Default: `false`
2776
2777**Options**
2778
2779`boolean` values
2780
2781**Example**
2782
2783```json
2784{
2785 "terminal": {
2786 "keep_selection_on_copy": true
2787 }
2788}
2789```
2790
2791### Terminal: Env
2792
2793- Description: Any key-value pairs added to this object will be added to the terminal's environment. Keys must be unique, use `:` to separate multiple values in a single variable
2794- Setting: `env`
2795- Default: `{}`
2796
2797**Example**
2798
2799```json
2800{
2801 "terminal": {
2802 "env": {
2803 "ZED": "1",
2804 "KEY": "value1:value2"
2805 }
2806 }
2807}
2808```
2809
2810### Terminal: Font Size
2811
2812- Description: What font size to use for the terminal. When not set defaults to matching the editor's font size
2813- Setting: `font_size`
2814- Default: `null`
2815
2816**Options**
2817
2818`integer` values
2819
2820```json
2821{
2822 "terminal": {
2823 "font_size": 15
2824 }
2825}
2826```
2827
2828### Terminal: Font Family
2829
2830- Description: What font to use for the terminal. When not set, defaults to matching the editor's font.
2831- Setting: `font_family`
2832- Default: `null`
2833
2834**Options**
2835
2836The name of any font family installed on the user's system
2837
2838```json
2839{
2840 "terminal": {
2841 "font_family": "Berkeley Mono"
2842 }
2843}
2844```
2845
2846### Terminal: Font Features
2847
2848- Description: What font features to use for the terminal. When not set, defaults to matching the editor's font features.
2849- Setting: `font_features`
2850- Default: `null`
2851- Platform: macOS and Windows.
2852
2853**Options**
2854
2855See Buffer Font Features
2856
2857```json
2858{
2859 "terminal": {
2860 "font_features": {
2861 "calt": false
2862 // See Buffer Font Features for more features
2863 }
2864 }
2865}
2866```
2867
2868### Terminal: Line Height
2869
2870- Description: Set the terminal's line height.
2871- Setting: `line_height`
2872- Default: `comfortable`
2873
2874**Options**
2875
28761. Use a line height that's `comfortable` for reading, 1.618. (default)
2877
2878```json
2879{
2880 "terminal": {
2881 "line_height": "comfortable"
2882 }
2883}
2884```
2885
28862. Use a `standard` line height, 1.3. This option is useful for TUIs, particularly if they use box characters
2887
2888```json
2889{
2890 "terminal": {
2891 "line_height": "standard"
2892 }
2893}
2894```
2895
28963. Use a custom line height.
2897
2898```json
2899{
2900 "terminal": {
2901 "line_height": {
2902 "custom": 2
2903 }
2904 }
2905}
2906```
2907
2908### Terminal: Minimum Contrast
2909
2910- Description: Controls the minimum contrast between foreground and background colors in the terminal. Uses the APCA (Accessible Perceptual Contrast Algorithm) for color adjustments. Set this to 0 to disable this feature.
2911- Setting: `minimum_contrast`
2912- Default: `45`
2913
2914**Options**
2915
2916`integer` values from 0 to 106. Common recommended values:
2917
2918- `0`: No contrast adjustment
2919- `45`: Minimum for large fluent text (default)
2920- `60`: Minimum for other content text
2921- `75`: Minimum for body text
2922- `90`: Preferred for body text
2923
2924```json
2925{
2926 "terminal": {
2927 "minimum_contrast": 45
2928 }
2929}
2930```
2931
2932### Terminal: Option As Meta
2933
2934- Description: Re-interprets the option keys to act like a 'meta' key, like in Emacs.
2935- Setting: `option_as_meta`
2936- Default: `false`
2937
2938**Options**
2939
2940`boolean` values
2941
2942```json
2943{
2944 "terminal": {
2945 "option_as_meta": true
2946 }
2947}
2948```
2949
2950### Terminal: Shell
2951
2952- Description: What shell to use when launching the terminal.
2953- Setting: `shell`
2954- Default: `system`
2955
2956**Options**
2957
29581. Use the system's default terminal configuration (usually the `/etc/passwd` file).
2959
2960```json
2961{
2962 "terminal": {
2963 "shell": "system"
2964 }
2965}
2966```
2967
29682. A program to launch:
2969
2970```json
2971{
2972 "terminal": {
2973 "shell": {
2974 "program": "sh"
2975 }
2976 }
2977}
2978```
2979
29803. A program with arguments:
2981
2982```json
2983{
2984 "terminal": {
2985 "shell": {
2986 "with_arguments": {
2987 "program": "/bin/bash",
2988 "args": ["--login"]
2989 }
2990 }
2991 }
2992}
2993```
2994
2995## Terminal: Detect Virtual Environments {#terminal-detect_venv}
2996
2997- Description: Activate the [Python Virtual Environment](https://docs.python.org/3/library/venv.html), if one is found, in the terminal's working directory (as resolved by the working_directory and automatically activating the virtual environment.
2998- Setting: `detect_venv`
2999- Default:
3000
3001```json
3002{
3003 "terminal": {
3004 "detect_venv": {
3005 "on": {
3006 // Default directories to search for virtual environments, relative
3007 // to the current working directory. We recommend overriding this
3008 // in your project's settings, rather than globally.
3009 "directories": [".env", "env", ".venv", "venv"],
3010 // Can also be `csh`, `fish`, and `nushell`
3011 "activate_script": "default"
3012 }
3013 }
3014 }
3015}
3016```
3017
3018Disable with:
3019
3020```json
3021{
3022 "terminal": {
3023 "detect_venv": "off"
3024 }
3025}
3026```
3027
3028## Terminal: Toolbar
3029
3030- Description: Whether or not to show various elements in the terminal toolbar.
3031- Setting: `toolbar`
3032- Default:
3033
3034```json
3035{
3036 "terminal": {
3037 "toolbar": {
3038 "breadcrumbs": true
3039 }
3040 }
3041}
3042```
3043
3044**Options**
3045
3046At the moment, only the `breadcrumbs` option is available, it controls displaying of the terminal title that can be changed via `PROMPT_COMMAND`.
3047
3048If the terminal title is empty, the breadcrumbs won't be shown.
3049
3050The shell running in the terminal needs to be configured to emit the title.
3051
3052Example command to set the title: `echo -e "\e]2;New Title\007";`
3053
3054### Terminal: Button
3055
3056- Description: Control to show or hide the terminal button in the status bar
3057- Setting: `button`
3058- Default: `true`
3059
3060**Options**
3061
3062`boolean` values
3063
3064```json
3065{
3066 "terminal": {
3067 "button": false
3068 }
3069}
3070```
3071
3072### Terminal: Working Directory
3073
3074- Description: What working directory to use when launching the terminal.
3075- Setting: `working_directory`
3076- Default: `"current_project_directory"`
3077
3078**Options**
3079
30801. Use the current file's project directory. Will Fallback to the first project directory strategy if unsuccessful
3081
3082```json
3083{
3084 "terminal": {
3085 "working_directory": "current_project_directory"
3086 }
3087}
3088```
3089
30902. Use the first project in this workspace's directory. Will fallback to using this platform's home directory.
3091
3092```json
3093{
3094 "terminal": {
3095 "working_directory": "first_project_directory"
3096 }
3097}
3098```
3099
31003. Always use this platform's home directory (if we can find it)
3101
3102```json
3103{
3104 "terminal": {
3105 "working_directory": "always_home"
3106 }
3107}
3108```
3109
31104. Always use a specific directory. This value will be shell expanded. If this path is not a valid directory the terminal will default to this platform's home directory.
3111
3112```json
3113{
3114 "terminal": {
3115 "working_directory": {
3116 "always": {
3117 "directory": "~/zed/projects/"
3118 }
3119 }
3120 }
3121}
3122```
3123
3124## Theme
3125
3126- Description: The theme setting can be specified in two forms - either as the name of a theme or as an object containing the `mode`, `dark`, and `light` themes for the Zed UI.
3127- Setting: `theme`
3128- Default: `One Dark`
3129
3130### Theme Object
3131
3132- Description: Specify the theme using an object that includes the `mode`, `dark`, and `light` themes.
3133- Setting: `theme`
3134- Default:
3135
3136```json
3137"theme": {
3138 "mode": "system",
3139 "dark": "One Dark",
3140 "light": "One Light"
3141},
3142```
3143
3144### Mode
3145
3146- Description: Specify theme mode.
3147- Setting: `mode`
3148- Default: `system`
3149
3150**Options**
3151
31521. Set the theme to dark mode
3153
3154```json
3155{
3156 "mode": "dark"
3157}
3158```
3159
31602. Set the theme to light mode
3161
3162```json
3163{
3164 "mode": "light"
3165}
3166```
3167
31683. Set the theme to system mode
3169
3170```json
3171{
3172 "mode": "system"
3173}
3174```
3175
3176### Dark
3177
3178- Description: The name of the dark Zed theme to use for the UI.
3179- Setting: `dark`
3180- Default: `One Dark`
3181
3182**Options**
3183
3184Run the `theme selector: toggle` action in the command palette to see a current list of valid themes names.
3185
3186### Light
3187
3188- Description: The name of the light Zed theme to use for the UI.
3189- Setting: `light`
3190- Default: `One Light`
3191
3192**Options**
3193
3194Run the `theme selector: toggle` action in the command palette to see a current list of valid themes names.
3195
3196## Vim
3197
3198- Description: Whether or not to enable vim mode. See the [Vim documentation](./vim.md) for more details on configuration.
3199- Setting: `vim_mode`
3200- Default: `false`
3201
3202## Helix Mode
3203
3204- Description: Whether or not to enable Helix mode. Enabling `helix_mode` also enables `vim_mode`. See the [Helix documentation](./helix.md) for more details.
3205- Setting: `helix_mode`
3206- Default: `false`
3207
3208## Project Panel
3209
3210- Description: Customize project panel
3211- Setting: `project_panel`
3212- Default:
3213
3214```json
3215{
3216 "project_panel": {
3217 "button": true,
3218 "default_width": 240,
3219 "dock": "left",
3220 "entry_spacing": "comfortable",
3221 "file_icons": true,
3222 "folder_icons": true,
3223 "git_status": true,
3224 "indent_size": 20,
3225 "auto_reveal_entries": true,
3226 "auto_fold_dirs": true,
3227 "scrollbar": {
3228 "show": null
3229 },
3230 "show_diagnostics": "all",
3231 "indent_guides": {
3232 "show": "always"
3233 },
3234 "hide_root": false,
3235 "starts_open": true
3236 }
3237}
3238```
3239
3240### Dock
3241
3242- Description: Control the position of the dock
3243- Setting: `dock`
3244- Default: `left`
3245
3246**Options**
3247
32481. Default dock position to left
3249
3250```json
3251{
3252 "dock": "left"
3253}
3254```
3255
32562. Default dock position to right
3257
3258```json
3259{
3260 "dock": "right"
3261}
3262```
3263
3264### Entry Spacing
3265
3266- Description: Spacing between worktree entries
3267- Setting: `entry_spacing`
3268- Default: `comfortable`
3269
3270**Options**
3271
32721. Comfortable entry spacing
3273
3274```json
3275{
3276 "entry_spacing": "comfortable"
3277}
3278```
3279
32802. Standard entry spacing
3281
3282```json
3283{
3284 "entry_spacing": "standard"
3285}
3286```
3287
3288### Git Status
3289
3290- Description: Indicates newly created and updated files
3291- Setting: `git_status`
3292- Default: `true`
3293
3294**Options**
3295
32961. Default enable git status
3297
3298```json
3299{
3300 "git_status": true
3301}
3302```
3303
33042. Default disable git status
3305
3306```json
3307{
3308 "git_status": false
3309}
3310```
3311
3312### Default Width
3313
3314- Description: Customize default width taken by project panel
3315- Setting: `default_width`
3316- Default: `240`
3317
3318**Options**
3319
3320`float` values
3321
3322### Auto Reveal Entries
3323
3324- Description: Whether to reveal it in the project panel automatically, when a corresponding project entry becomes active. Gitignored entries are never auto revealed.
3325- Setting: `auto_reveal_entries`
3326- Default: `true`
3327
3328**Options**
3329
33301. Enable auto reveal entries
3331
3332```json
3333{
3334 "auto_reveal_entries": true
3335}
3336```
3337
33382. Disable auto reveal entries
3339
3340```json
3341{
3342 "auto_reveal_entries": false
3343}
3344```
3345
3346### Auto Fold Dirs
3347
3348- Description: Whether to fold directories automatically when directory has only one directory inside.
3349- Setting: `auto_fold_dirs`
3350- Default: `true`
3351
3352**Options**
3353
33541. Enable auto fold dirs
3355
3356```json
3357{
3358 "auto_fold_dirs": true
3359}
3360```
3361
33622. Disable auto fold dirs
3363
3364```json
3365{
3366 "auto_fold_dirs": false
3367}
3368```
3369
3370### Indent Size
3371
3372- Description: Amount of indentation (in pixels) for nested items.
3373- Setting: `indent_size`
3374- Default: `20`
3375
3376### Indent Guides: Show
3377
3378- Description: Whether to show indent guides in the project panel.
3379- Setting: `indent_guides`
3380- Default:
3381
3382```json
3383"indent_guides": {
3384 "show": "always"
3385}
3386```
3387
3388**Options**
3389
33901. Show indent guides in the project panel
3391
3392```json
3393{
3394 "indent_guides": {
3395 "show": "always"
3396 }
3397}
3398```
3399
34002. Hide indent guides in the project panel
3401
3402```json
3403{
3404 "indent_guides": {
3405 "show": "never"
3406 }
3407}
3408```
3409
3410### Scrollbar: Show
3411
3412- Description: Whether to show a scrollbar in the project panel. Possible values: null, "auto", "system", "always", "never". Inherits editor settings when absent, see its description for more details.
3413- Setting: `scrollbar`
3414- Default:
3415
3416```json
3417"scrollbar": {
3418 "show": null
3419}
3420```
3421
3422**Options**
3423
34241. Show scrollbar in the project panel
3425
3426```json
3427{
3428 "scrollbar": {
3429 "show": "always"
3430 }
3431}
3432```
3433
34342. Hide scrollbar in the project panel
3435
3436```json
3437{
3438 "scrollbar": {
3439 "show": "never"
3440 }
3441}
3442```
3443
3444## Agent
3445
3446Visit [the Configuration page](./ai/configuration.md) under the AI section to learn more about all the agent-related settings.
3447
3448## Outline Panel
3449
3450- Description: Customize outline Panel
3451- Setting: `outline_panel`
3452- Default:
3453
3454```json
3455"outline_panel": {
3456 "button": true,
3457 "default_width": 300,
3458 "dock": "left",
3459 "file_icons": true,
3460 "folder_icons": true,
3461 "git_status": true,
3462 "indent_size": 20,
3463 "auto_reveal_entries": true,
3464 "auto_fold_dirs": true,
3465 "indent_guides": {
3466 "show": "always"
3467 },
3468 "scrollbar": {
3469 "show": null
3470 }
3471}
3472```
3473
3474## Calls
3475
3476- Description: Customize behavior when participating in a call
3477- Setting: `calls`
3478- Default:
3479
3480```json
3481"calls": {
3482 // Join calls with the microphone live by default
3483 "mute_on_join": false,
3484 // Share your project when you are the first to join a channel
3485 "share_on_join": false
3486},
3487```
3488
3489## Unnecessary Code Fade
3490
3491- Description: How much to fade out unused code.
3492- Setting: `unnecessary_code_fade`
3493- Default: `0.3`
3494
3495**Options**
3496
3497Float values between `0.0` and `0.9`, where:
3498
3499- `0.0` means no fading (unused code looks the same as used code)
3500- `0.9` means maximum fading (unused code is very faint but still visible)
3501
3502**Example**
3503
3504```json
3505{
3506 "unnecessary_code_fade": 0.5
3507}
3508```
3509
3510## UI Font Family
3511
3512- Description: The name of the font to use for text in the UI.
3513- Setting: `ui_font_family`
3514- Default: `.ZedSans`. This currently aliases to [IBM Plex](https://www.ibm.com/plex/).
3515
3516**Options**
3517
3518The name of any font family installed on the system, `".ZedSans"` to use the Zed-provided default, or `".SystemUIFont"` to use the system's default UI font (on macOS and Windows).
3519
3520## UI Font Features
3521
3522- Description: The OpenType features to enable for text in the UI.
3523- Setting: `ui_font_features`
3524- Default:
3525
3526```json
3527"ui_font_features": {
3528 "calt": false
3529}
3530```
3531
3532- Platform: macOS and Windows.
3533
3534**Options**
3535
3536Zed supports all OpenType features that can be enabled or disabled for a given UI font, as well as setting values for font features.
3537
3538For example, to disable font ligatures, add the following to your settings:
3539
3540```json
3541{
3542 "ui_font_features": {
3543 "calt": false
3544 }
3545}
3546```
3547
3548You can also set other OpenType features, like setting `cv01` to `7`:
3549
3550```json
3551{
3552 "ui_font_features": {
3553 "cv01": 7
3554 }
3555}
3556```
3557
3558## UI Font Fallbacks
3559
3560- Description: The font fallbacks to use for text in the UI.
3561- Setting: `ui_font_fallbacks`
3562- Default: `null`
3563- Platform: macOS and Windows.
3564
3565**Options**
3566
3567For example, to use `Nerd Font` as a fallback, add the following to your settings:
3568
3569```json
3570{
3571 "ui_font_fallbacks": ["Nerd Font"]
3572}
3573```
3574
3575## UI Font Size
3576
3577- Description: The default font size for text in the UI.
3578- Setting: `ui_font_size`
3579- Default: `16`
3580
3581**Options**
3582
3583`integer` values from `6` to `100` pixels (inclusive)
3584
3585## UI Font Weight
3586
3587- Description: The default font weight for text in the UI.
3588- Setting: `ui_font_weight`
3589- Default: `400`
3590
3591**Options**
3592
3593`integer` values between `100` and `900`
3594
3595## An example configuration:
3596
3597```json
3598// ~/.config/zed/settings.json
3599{
3600 "theme": "cave-light",
3601 "tab_size": 2,
3602 "preferred_line_length": 80,
3603 "soft_wrap": "none",
3604
3605 "buffer_font_size": 18,
3606 "buffer_font_family": ".ZedMono",
3607
3608 "autosave": "on_focus_change",
3609 "format_on_save": "off",
3610 "vim_mode": false,
3611 "projects_online_by_default": true,
3612 "terminal": {
3613 "font_family": "FiraCode Nerd Font Mono",
3614 "blinking": "off"
3615 },
3616 "languages": {
3617 "C": {
3618 "format_on_save": "language_server",
3619 "preferred_line_length": 64,
3620 "soft_wrap": "preferred_line_length"
3621 }
3622 }
3623}
3624```