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## Cursor Blink
543
544- Description: Whether or not the cursor blinks.
545- Setting: `cursor_blink`
546- Default: `true`
547
548**Options**
549
550`boolean` values
551
552## Cursor Shape
553
554- Description: Cursor shape for the default editor.
555- Setting: `cursor_shape`
556- Default: `bar`
557
558**Options**
559
5601. A vertical bar:
561
562```json
563"cursor_shape": "bar"
564```
565
5662. A block that surrounds the following character:
567
568```json
569"cursor_shape": "block"
570```
571
5723. An underline / underscore that runs along the following character:
573
574```json
575"cursor_shape": "underline"
576```
577
5784. An box drawn around the following character:
579
580```json
581"cursor_shape": "hollow"
582```
583
584## Hide Mouse
585
586- Description: Determines when the mouse cursor should be hidden in an editor or input box.
587- Setting: `hide_mouse`
588- Default: `on_typing_and_movement`
589
590**Options**
591
5921. Never hide the mouse cursor:
593
594```json
595"hide_mouse": "never"
596```
597
5982. Hide only when typing:
599
600```json
601"hide_mouse": "on_typing"
602```
603
6043. Hide on both typing and cursor movement:
605
606```json
607"hide_mouse": "on_typing_and_movement"
608```
609
610## Snippet Sort Order
611
612- Description: Determines how snippets are sorted relative to other completion items.
613- Setting: `snippet_sort_order`
614- Default: `inline`
615
616**Options**
617
6181. Place snippets at the top of the completion list:
619
620```json
621"snippet_sort_order": "top"
622```
623
6242. Place snippets normally without any preference:
625
626```json
627"snippet_sort_order": "inline"
628```
629
6303. Place snippets at the bottom of the completion list:
631
632```json
633"snippet_sort_order": "bottom"
634```
635
6364. Do not show snippets in the completion list at all:
637
638```json
639"snippet_sort_order": "none"
640```
641
642## Editor Scrollbar
643
644- Description: Whether or not to show the editor scrollbar and various elements in it.
645- Setting: `scrollbar`
646- Default:
647
648```json
649"scrollbar": {
650 "show": "auto",
651 "cursors": true,
652 "git_diff": true,
653 "search_results": true,
654 "selected_text": true,
655 "selected_symbol": true,
656 "diagnostics": "all",
657 "axes": {
658 "horizontal": true,
659 "vertical": true,
660 },
661},
662```
663
664### Show Mode
665
666- Description: When to show the editor scrollbar.
667- Setting: `show`
668- Default: `auto`
669
670**Options**
671
6721. Show the scrollbar if there's important information or follow the system's configured behavior:
673
674```json
675"scrollbar": {
676 "show": "auto"
677}
678```
679
6802. Match the system's configured behavior:
681
682```json
683"scrollbar": {
684 "show": "system"
685}
686```
687
6883. Always show the scrollbar:
689
690```json
691"scrollbar": {
692 "show": "always"
693}
694```
695
6964. Never show the scrollbar:
697
698```json
699"scrollbar": {
700 "show": "never"
701}
702```
703
704### Cursor Indicators
705
706- Description: Whether to show cursor positions in the scrollbar.
707- Setting: `cursors`
708- Default: `true`
709
710**Options**
711
712`boolean` values
713
714### Git Diff Indicators
715
716- Description: Whether to show git diff indicators in the scrollbar.
717- Setting: `git_diff`
718- Default: `true`
719
720**Options**
721
722`boolean` values
723
724### Search Results Indicators
725
726- Description: Whether to show buffer search results in the scrollbar.
727- Setting: `search_results`
728- Default: `true`
729
730**Options**
731
732`boolean` values
733
734### Selected Text Indicators
735
736- Description: Whether to show selected text occurrences in the scrollbar.
737- Setting: `selected_text`
738- Default: `true`
739
740**Options**
741
742`boolean` values
743
744### Selected Symbols Indicators
745
746- Description: Whether to show selected symbol occurrences in the scrollbar.
747- Setting: `selected_symbol`
748- Default: `true`
749
750**Options**
751
752`boolean` values
753
754### Diagnostics
755
756- Description: Which diagnostic indicators to show in the scrollbar.
757- Setting: `diagnostics`
758- Default: `all`
759
760**Options**
761
7621. Show all diagnostics:
763
764```json
765{
766 "diagnostics": "all"
767}
768```
769
7702. Do not show any diagnostics:
771
772```json
773{
774 "diagnostics": "none"
775}
776```
777
7783. Show only errors:
779
780```json
781{
782 "diagnostics": "error"
783}
784```
785
7864. Show only errors and warnings:
787
788```json
789{
790 "diagnostics": "warning"
791}
792```
793
7945. Show only errors, warnings, and information:
795
796```json
797{
798 "diagnostics": "information"
799}
800```
801
802### Axes
803
804- Description: Forcefully enable or disable the scrollbar for each axis
805- Setting: `axes`
806- Default:
807
808```json
809"scrollbar": {
810 "axes": {
811 "horizontal": true,
812 "vertical": true,
813 },
814}
815```
816
817#### Horizontal
818
819- Description: When false, forcefully disables the horizontal scrollbar. Otherwise, obey other settings.
820- Setting: `horizontal`
821- Default: `true`
822
823**Options**
824
825`boolean` values
826
827#### Vertical
828
829- Description: When false, forcefully disables the vertical scrollbar. Otherwise, obey other settings.
830- Setting: `vertical`
831- Default: `true`
832
833**Options**
834
835`boolean` values
836
837## Minimap
838
839- Description: Settings related to the editor's minimap, which provides an overview of your document.
840- Setting: `minimap`
841- Default:
842
843```json
844{
845 "minimap": {
846 "show": "never",
847 "thumb": "always",
848 "thumb_border": "left_open",
849 "current_line_highlight": null
850 }
851}
852```
853
854### Show Mode
855
856- Description: When to show the minimap in the editor.
857- Setting: `show`
858- Default: `never`
859
860**Options**
861
8621. Always show the minimap:
863
864```json
865{
866 "show": "always"
867}
868```
869
8702. Show the minimap if the editor's scrollbars are visible:
871
872```json
873{
874 "show": "auto"
875}
876```
877
8783. Never show the minimap:
879
880```json
881{
882 "show": "never"
883}
884```
885
886### Thumb Display
887
888- Description: When to show the minimap thumb (the visible editor area) in the minimap.
889- Setting: `thumb`
890- Default: `always`
891
892**Options**
893
8941. Show the minimap thumb when hovering over the minimap:
895
896```json
897{
898 "thumb": "hover"
899}
900```
901
9022. Always show the minimap thumb:
903
904```json
905{
906 "thumb": "always"
907}
908```
909
910### Thumb Border
911
912- Description: How the minimap thumb border should look.
913- Setting: `thumb_border`
914- Default: `left_open`
915
916**Options**
917
9181. Display a border on all sides of the thumb:
919
920```json
921{
922 "thumb_border": "full"
923}
924```
925
9262. Display a border on all sides except the left side:
927
928```json
929{
930 "thumb_border": "left_open"
931}
932```
933
9343. Display a border on all sides except the right side:
935
936```json
937{
938 "thumb_border": "right_open"
939}
940```
941
9424. Display a border only on the left side:
943
944```json
945{
946 "thumb_border": "left_only"
947}
948```
949
9505. Display the thumb without any border:
951
952```json
953{
954 "thumb_border": "none"
955}
956```
957
958### Current Line Highlight
959
960- Description: How to highlight the current line in the minimap.
961- Setting: `current_line_highlight`
962- Default: `null`
963
964**Options**
965
9661. Inherit the editor's current line highlight setting:
967
968```json
969{
970 "minimap": {
971 "current_line_highlight": null
972 }
973}
974```
975
9762. Highlight the current line in the minimap:
977
978```json
979{
980 "minimap": {
981 "current_line_highlight": "line"
982 }
983}
984```
985
986or
987
988```json
989{
990 "minimap": {
991 "current_line_highlight": "all"
992 }
993}
994```
995
9963. Do not highlight the current line in the minimap:
997
998```json
999{
1000 "minimap": {
1001 "current_line_highlight": "gutter"
1002 }
1003}
1004```
1005
1006or
1007
1008```json
1009{
1010 "minimap": {
1011 "current_line_highlight": "none"
1012 }
1013}
1014```
1015
1016## Editor Tab Bar
1017
1018- Description: Settings related to the editor's tab bar.
1019- Settings: `tab_bar`
1020- Default:
1021
1022```json
1023"tab_bar": {
1024 "show": true,
1025 "show_nav_history_buttons": true,
1026 "show_tab_bar_buttons": true
1027}
1028```
1029
1030### Show
1031
1032- Description: Whether or not to show the tab bar in the editor.
1033- Setting: `show`
1034- Default: `true`
1035
1036**Options**
1037
1038`boolean` values
1039
1040### Navigation History Buttons
1041
1042- Description: Whether or not to show the navigation history buttons.
1043- Setting: `show_nav_history_buttons`
1044- Default: `true`
1045
1046**Options**
1047
1048`boolean` values
1049
1050### Tab Bar Buttons
1051
1052- Description: Whether or not to show the tab bar buttons.
1053- Setting: `show_tab_bar_buttons`
1054- Default: `true`
1055
1056**Options**
1057
1058`boolean` values
1059
1060## Editor Tabs
1061
1062- Description: Configuration for the editor tabs.
1063- Setting: `tabs`
1064- Default:
1065
1066```json
1067"tabs": {
1068 "close_position": "right",
1069 "file_icons": false,
1070 "git_status": false,
1071 "activate_on_close": "history",
1072 "show_close_button": "hover",
1073 "show_diagnostics": "off"
1074},
1075```
1076
1077### Close Position
1078
1079- Description: Where to display close button within a tab.
1080- Setting: `close_position`
1081- Default: `right`
1082
1083**Options**
1084
10851. Display the close button on the right:
1086
1087```json
1088{
1089 "close_position": "right"
1090}
1091```
1092
10932. Display the close button on the left:
1094
1095```json
1096{
1097 "close_position": "left"
1098}
1099```
1100
1101### File Icons
1102
1103- Description: Whether to show the file icon for a tab.
1104- Setting: `file_icons`
1105- Default: `false`
1106
1107### Git Status
1108
1109- Description: Whether or not to show Git file status in tab.
1110- Setting: `git_status`
1111- Default: `false`
1112
1113### Activate on close
1114
1115- Description: What to do after closing the current tab.
1116- Setting: `activate_on_close`
1117- Default: `history`
1118
1119**Options**
1120
11211. Activate the tab that was open previously:
1122
1123```json
1124{
1125 "activate_on_close": "history"
1126}
1127```
1128
11292. Activate the right neighbour tab if present:
1130
1131```json
1132{
1133 "activate_on_close": "neighbour"
1134}
1135```
1136
11373. Activate the left neighbour tab if present:
1138
1139```json
1140{
1141 "activate_on_close": "left_neighbour"
1142}
1143```
1144
1145### Show close button
1146
1147- Description: Controls the appearance behavior of the tab's close button.
1148- Setting: `show_close_button`
1149- Default: `hover`
1150
1151**Options**
1152
11531. Show it just upon hovering the tab:
1154
1155```json
1156{
1157 "show_close_button": "hover"
1158}
1159```
1160
11612. Show it persistently:
1162
1163```json
1164{
1165 "show_close_button": "always"
1166}
1167```
1168
11693. Never show it, even if hovering it:
1170
1171```json
1172{
1173 "show_close_button": "hidden"
1174}
1175```
1176
1177### Show Diagnostics
1178
1179- 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.
1180- Setting: `show_diagnostics`
1181- Default: `off`
1182
1183**Options**
1184
11851. Do not mark any files:
1186
1187```json
1188{
1189 "show_diagnostics": "off"
1190}
1191```
1192
11932. Only mark files with errors:
1194
1195```json
1196{
1197 "show_diagnostics": "errors"
1198}
1199```
1200
12013. Mark files with errors and warnings:
1202
1203```json
1204{
1205 "show_diagnostics": "all"
1206}
1207```
1208
1209### Show Inline Code Actions
1210
1211- Description: Whether to show code action button at start of buffer line.
1212- Setting: `inline_code_actions`
1213- Default: `true`
1214
1215**Options**
1216
1217`boolean` values
1218
1219### Drag And Drop Selection
1220
1221- 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.
1222- Setting: `drag_and_drop_selection`
1223- Default:
1224
1225```json
1226"drag_and_drop_selection": {
1227 "enabled": true,
1228 "delay": 300
1229}
1230```
1231
1232## Editor Toolbar
1233
1234- Description: Whether or not to show various elements in the editor toolbar.
1235- Setting: `toolbar`
1236- Default:
1237
1238```json
1239"toolbar": {
1240 "breadcrumbs": true,
1241 "quick_actions": true,
1242 "selections_menu": true,
1243 "agent_review": true,
1244 "code_actions": false
1245},
1246```
1247
1248**Options**
1249
1250Each option controls displaying of a particular toolbar element. If all elements are hidden, the editor toolbar is not displayed.
1251
1252## Enable Language Server
1253
1254- Description: Whether or not to use language servers to provide code intelligence.
1255- Setting: `enable_language_server`
1256- Default: `true`
1257
1258**Options**
1259
1260`boolean` values
1261
1262## Ensure Final Newline On Save
1263
1264- Description: Removes any lines containing only whitespace at the end of the file and ensures just one newline at the end.
1265- Setting: `ensure_final_newline_on_save`
1266- Default: `true`
1267
1268**Options**
1269
1270`boolean` values
1271
1272## Status Bar
1273
1274- Description: Control various elements in the status bar. Note that some items in the status bar have their own settings set elsewhere.
1275- Setting: `status_bar`
1276- Default:
1277
1278```json
1279"status_bar": {
1280 "active_language_button": true,
1281 "cursor_position_button": true
1282},
1283```
1284
1285## LSP
1286
1287- Description: Configuration for language servers.
1288- Setting: `lsp`
1289- Default: `null`
1290
1291**Options**
1292
1293The following settings can be overridden for specific language servers:
1294
1295- `initialization_options`
1296- `settings`
1297
1298To override configuration for a language server, add an entry for that language server's name to the `lsp` value.
1299
1300Some 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.
1301
1302For example to pass the `check` option to `rust-analyzer`, use the following configuration:
1303
1304```json
1305"lsp": {
1306 "rust-analyzer": {
1307 "initialization_options": {
1308 "check": {
1309 "command": "clippy" // rust-analyzer.check.command (default: "check")
1310 }
1311 }
1312 }
1313}
1314```
1315
1316While other options may be changed at a runtime and should be placed under `settings`:
1317
1318```json
1319"lsp": {
1320 "yaml-language-server": {
1321 "settings": {
1322 "yaml": {
1323 "keyOrdering": true // Enforces alphabetical ordering of keys in maps
1324 }
1325 }
1326 }
1327}
1328```
1329
1330## LSP Highlight Debounce
1331
1332- Description: The debounce delay in milliseconds before querying highlights from the language server based on the current cursor location.
1333- Setting: `lsp_highlight_debounce`
1334- Default: `75`
1335
1336## Global LSP Settings
1337
1338- Description: Common language server settings.
1339- Setting: `global_lsp_settings`
1340- Default:
1341
1342```json
1343"global_lsp_settings": {
1344 "button": true
1345}
1346```
1347
1348**Options**
1349
1350`integer` values representing milliseconds
1351
1352## Format On Save
1353
1354- Description: Whether or not to perform a buffer format before saving.
1355- Setting: `format_on_save`
1356- Default: `on`
1357
1358**Options**
1359
13601. `on`, enables format on save obeying `formatter` setting:
1361
1362```json
1363{
1364 "format_on_save": "on"
1365}
1366```
1367
13682. `off`, disables format on save:
1369
1370```json
1371{
1372 "format_on_save": "off"
1373}
1374```
1375
1376## Formatter
1377
1378- Description: How to perform a buffer format.
1379- Setting: `formatter`
1380- Default: `auto`
1381
1382**Options**
1383
13841. To use the current language server, use `"language_server"`:
1385
1386```json
1387{
1388 "formatter": "language_server"
1389}
1390```
1391
13922. 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):
1393
1394```json
1395{
1396 "formatter": {
1397 "external": {
1398 "command": "sed",
1399 "arguments": ["-e", "s/ *$//"]
1400 }
1401 }
1402}
1403```
1404
14053. 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.
1406
1407WARNING: `{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.
1408
1409```json
1410 "formatter": {
1411 "external": {
1412 "command": "prettier",
1413 "arguments": ["--stdin-filepath", "{buffer_path}"]
1414 }
1415 }
1416```
1417
14184. Or to use code actions provided by the connected language servers, use `"code_actions"`:
1419
1420```json
1421{
1422 "formatter": {
1423 "code_actions": {
1424 // Use ESLint's --fix:
1425 "source.fixAll.eslint": true,
1426 // Organize imports on save:
1427 "source.organizeImports": true
1428 }
1429 }
1430}
1431```
1432
14335. Or to use multiple formatters consecutively, use an array of formatters:
1434
1435```json
1436{
1437 "formatter": [
1438 { "language_server": { "name": "rust-analyzer" } },
1439 {
1440 "external": {
1441 "command": "sed",
1442 "arguments": ["-e", "s/ *$//"]
1443 }
1444 }
1445 ]
1446}
1447```
1448
1449Here `rust-analyzer` will be used first to format the code, followed by a call of sed.
1450If any of the formatters fails, the subsequent ones will still be executed.
1451
1452## Code Actions On Format
1453
1454- Description: The code actions to perform with the primary language server when formatting the buffer.
1455- Setting: `code_actions_on_format`
1456- Default: `{}`, except for Go it's `{ "source.organizeImports": true }`
1457
1458**Examples**
1459
1460<!--
1461TBD: Add Python Ruff source.organizeImports example
1462-->
1463
14641. Organize imports on format in TypeScript and TSX buffers:
1465
1466```json
1467{
1468 "languages": {
1469 "TypeScript": {
1470 "code_actions_on_format": {
1471 "source.organizeImports": true
1472 }
1473 },
1474 "TSX": {
1475 "code_actions_on_format": {
1476 "source.organizeImports": true
1477 }
1478 }
1479 }
1480}
1481```
1482
14832. Run ESLint `fixAll` code action when formatting:
1484
1485```json
1486{
1487 "languages": {
1488 "JavaScript": {
1489 "code_actions_on_format": {
1490 "source.fixAll.eslint": true
1491 }
1492 }
1493 }
1494}
1495```
1496
14973. Run only a single ESLint rule when using `fixAll`:
1498
1499```json
1500{
1501 "languages": {
1502 "JavaScript": {
1503 "code_actions_on_format": {
1504 "source.fixAll.eslint": true
1505 }
1506 }
1507 },
1508 "lsp": {
1509 "eslint": {
1510 "settings": {
1511 "codeActionOnSave": {
1512 "rules": ["import/order"]
1513 }
1514 }
1515 }
1516 }
1517}
1518```
1519
1520## Auto close
1521
1522- Description: Whether to automatically add matching closing characters when typing opening parenthesis, bracket, brace, single or double quote characters.
1523- Setting: `use_autoclose`
1524- Default: `true`
1525
1526**Options**
1527
1528`boolean` values
1529
1530## Always Treat Brackets As Autoclosed
1531
1532- Description: Controls how the editor handles the autoclosed characters.
1533- Setting: `always_treat_brackets_as_autoclosed`
1534- Default: `false`
1535
1536**Options**
1537
1538`boolean` values
1539
1540**Example**
1541
1542If the setting is set to `true`:
1543
15441. Enter in the editor: `)))`
15452. Move the cursor to the start: `^)))`
15463. Enter again: `)))`
1547
1548The result is still `)))` and not `))))))`, which is what it would be by default.
1549
1550## File Scan Exclusions
1551
1552- Setting: `file_scan_exclusions`
1553- 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`.
1554- Default:
1555
1556```json
1557"file_scan_exclusions": [
1558 "**/.git",
1559 "**/.svn",
1560 "**/.hg",
1561 "**/.jj",
1562 "**/CVS",
1563 "**/.DS_Store",
1564 "**/Thumbs.db",
1565 "**/.classpath",
1566 "**/.settings"
1567],
1568```
1569
1570Note, 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.
1571
1572## File Scan Inclusions
1573
1574- Setting: `file_scan_inclusions`
1575- 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.
1576- Default:
1577
1578```json
1579"file_scan_inclusions": [".env*"],
1580```
1581
1582## File Types
1583
1584- Setting: `file_types`
1585- Description: Configure how Zed selects a language for a file based on its filename or extension. Supports glob entries.
1586- Default:
1587
1588```json
1589"file_types": {
1590 "JSONC": ["**/.zed/**/*.json", "**/zed/**/*.json", "**/Zed/**/*.json", "**/.vscode/**/*.json"],
1591 "Shell Script": [".env.*"]
1592}
1593```
1594
1595**Examples**
1596
1597To interpret all `.c` files as C++, files called `MyLockFile` as TOML and files starting with `Dockerfile` as Dockerfile:
1598
1599```json
1600{
1601 "file_types": {
1602 "C++": ["c"],
1603 "TOML": ["MyLockFile"],
1604 "Dockerfile": ["Dockerfile*"]
1605 }
1606}
1607```
1608
1609## Diagnostics
1610
1611- Description: Configuration for diagnostics-related features.
1612- Setting: `diagnostics`
1613- Default:
1614
1615```json
1616{
1617 "diagnostics": {
1618 "include_warnings": true,
1619 "inline": {
1620 "enabled": false
1621 },
1622 "update_with_cursor": false,
1623 "primary_only": false,
1624 "use_rendered": false
1625 }
1626}
1627```
1628
1629### Inline Diagnostics
1630
1631- Description: Whether or not to show diagnostics information inline.
1632- Setting: `inline`
1633- Default:
1634
1635```json
1636{
1637 "diagnostics": {
1638 "inline": {
1639 "enabled": false,
1640 "update_debounce_ms": 150,
1641 "padding": 4,
1642 "min_column": 0,
1643 "max_severity": null
1644 }
1645 }
1646}
1647```
1648
1649**Options**
1650
16511. Enable inline diagnostics.
1652
1653```json
1654{
1655 "diagnostics": {
1656 "inline": {
1657 "enabled": true
1658 }
1659 }
1660}
1661```
1662
16632. Delay diagnostic updates until some time after the last diagnostic update.
1664
1665```json
1666{
1667 "diagnostics": {
1668 "inline": {
1669 "enabled": true,
1670 "update_debounce_ms": 150
1671 }
1672 }
1673}
1674```
1675
16763. Set padding between the end of the source line and the start of the diagnostic.
1677
1678```json
1679{
1680 "diagnostics": {
1681 "inline": {
1682 "enabled": true,
1683 "padding": 4
1684 }
1685 }
1686}
1687```
1688
16894. Horizontally align inline diagnostics at the given column.
1690
1691```json
1692{
1693 "diagnostics": {
1694 "inline": {
1695 "enabled": true,
1696 "min_column": 80
1697 }
1698 }
1699}
1700```
1701
17025. Show only warning and error diagnostics.
1703
1704```json
1705{
1706 "diagnostics": {
1707 "inline": {
1708 "enabled": true,
1709 "max_severity": "warning"
1710 }
1711 }
1712}
1713```
1714
1715## Git
1716
1717- Description: Configuration for git-related features.
1718- Setting: `git`
1719- Default:
1720
1721```json
1722{
1723 "git": {
1724 "git_gutter": "tracked_files",
1725 "inline_blame": {
1726 "enabled": true
1727 },
1728 "hunk_style": "staged_hollow"
1729 }
1730}
1731```
1732
1733### Git Gutter
1734
1735- Description: Whether or not to show the git gutter.
1736- Setting: `git_gutter`
1737- Default: `tracked_files`
1738
1739**Options**
1740
17411. Show git gutter in tracked files
1742
1743```json
1744{
1745 "git": {
1746 "git_gutter": "tracked_files"
1747 }
1748}
1749```
1750
17512. Hide git gutter
1752
1753```json
1754{
1755 "git": {
1756 "git_gutter": "hide"
1757 }
1758}
1759```
1760
1761### Gutter Debounce
1762
1763- Description: Sets the debounce threshold (in milliseconds) after which changes are reflected in the git gutter.
1764- Setting: `gutter_debounce`
1765- Default: `null`
1766
1767**Options**
1768
1769`integer` values representing milliseconds
1770
1771Example:
1772
1773```json
1774{
1775 "git": {
1776 "gutter_debounce": 100
1777 }
1778}
1779```
1780
1781### Inline Git Blame
1782
1783- Description: Whether or not to show git blame information inline, on the currently focused line.
1784- Setting: `inline_blame`
1785- Default:
1786
1787```json
1788{
1789 "git": {
1790 "inline_blame": {
1791 "enabled": true
1792 }
1793 }
1794}
1795```
1796
1797**Options**
1798
17991. Disable inline git blame:
1800
1801```json
1802{
1803 "git": {
1804 "inline_blame": {
1805 "enabled": false
1806 }
1807 }
1808}
1809```
1810
18112. Only show inline git blame after a delay (that starts after cursor stops moving):
1812
1813```json
1814{
1815 "git": {
1816 "inline_blame": {
1817 "delay_ms": 500
1818 }
1819 }
1820}
1821```
1822
18233. Show a commit summary next to the commit date and author:
1824
1825```json
1826{
1827 "git": {
1828 "inline_blame": {
1829 "show_commit_summary": true
1830 }
1831 }
1832}
1833```
1834
18354. Use this as the minimum column at which to display inline blame information:
1836
1837```json
1838{
1839 "git": {
1840 "inline_blame": {
1841 "min_column": 80
1842 }
1843 }
1844}
1845```
1846
18475. Set the padding between the end of the line and the inline blame hint, in ems:
1848
1849```json
1850{
1851 "git": {
1852 "inline_blame": {
1853 "padding": 10
1854 }
1855 }
1856}
1857```
1858
1859### Hunk Style
1860
1861- Description: What styling we should use for the diff hunks.
1862- Setting: `hunk_style`
1863- Default:
1864
1865```json
1866{
1867 "git": {
1868 "hunk_style": "staged_hollow"
1869 }
1870}
1871```
1872
1873**Options**
1874
18751. Show the staged hunks faded out and with a border:
1876
1877```json
1878{
1879 "git": {
1880 "hunk_style": "staged_hollow"
1881 }
1882}
1883```
1884
18852. Show unstaged hunks faded out and with a border:
1886
1887```json
1888{
1889 "git": {
1890 "hunk_style": "unstaged_hollow"
1891 }
1892}
1893```
1894
1895## Indent Guides
1896
1897- Description: Configuration related to indent guides. Indent guides can be configured separately for each language.
1898- Setting: `indent_guides`
1899- Default:
1900
1901```json
1902{
1903 "indent_guides": {
1904 "enabled": true,
1905 "line_width": 1,
1906 "active_line_width": 1,
1907 "coloring": "fixed",
1908 "background_coloring": "disabled"
1909 }
1910}
1911```
1912
1913**Options**
1914
19151. Disable indent guides
1916
1917```json
1918{
1919 "indent_guides": {
1920 "enabled": false
1921 }
1922}
1923```
1924
19252. Enable indent guides for a specific language.
1926
1927```json
1928{
1929 "languages": {
1930 "Python": {
1931 "indent_guides": {
1932 "enabled": true
1933 }
1934 }
1935 }
1936}
1937```
1938
19393. Enable indent aware coloring ("rainbow indentation").
1940 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.
1941
1942```json
1943{
1944 "indent_guides": {
1945 "enabled": true,
1946 "coloring": "indent_aware"
1947 }
1948}
1949```
1950
19514. Enable indent aware background coloring ("rainbow indentation").
1952 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.
1953
1954```json
1955{
1956 "indent_guides": {
1957 "enabled": true,
1958 "coloring": "indent_aware",
1959 "background_coloring": "indent_aware"
1960 }
1961}
1962```
1963
1964## Hard Tabs
1965
1966- Description: Whether to indent lines using tab characters or multiple spaces.
1967- Setting: `hard_tabs`
1968- Default: `false`
1969
1970**Options**
1971
1972`boolean` values
1973
1974## Multi Cursor Modifier
1975
1976- 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.
1977- Setting: `multi_cursor_modifier`
1978- Default: `alt`
1979
1980**Options**
1981
19821. Maps to `Alt` on Linux and Windows and to `Option` on MacOS:
1983
1984```json
1985{
1986 "multi_cursor_modifier": "alt"
1987}
1988```
1989
19902. Maps `Control` on Linux and Windows and to `Command` on MacOS:
1991
1992```json
1993{
1994 "multi_cursor_modifier": "cmd_or_ctrl" // alias: "cmd", "ctrl"
1995}
1996```
1997
1998## Hover Popover Enabled
1999
2000- Description: Whether or not to show the informational hover box when moving the mouse over symbols in the editor.
2001- Setting: `hover_popover_enabled`
2002- Default: `true`
2003
2004**Options**
2005
2006`boolean` values
2007
2008## Hover Popover Delay
2009
2010- Description: Time to wait in milliseconds before showing the informational hover box.
2011- Setting: `hover_popover_delay`
2012- Default: `300`
2013
2014**Options**
2015
2016`integer` values representing milliseconds
2017
2018## Icon Theme
2019
2020- 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.
2021- Setting: `icon_theme`
2022- Default: `Zed (Default)`
2023
2024### Icon Theme Object
2025
2026- Description: Specify the icon theme using an object that includes the `mode`, `dark`, and `light`.
2027- Setting: `icon_theme`
2028- Default:
2029
2030```json
2031"icon_theme": {
2032 "mode": "system",
2033 "dark": "Zed (Default)",
2034 "light": "Zed (Default)"
2035},
2036```
2037
2038### Mode
2039
2040- Description: Specify the icon theme mode.
2041- Setting: `mode`
2042- Default: `system`
2043
2044**Options**
2045
20461. Set the icon theme to dark mode
2047
2048```json
2049{
2050 "mode": "dark"
2051}
2052```
2053
20542. Set the icon theme to light mode
2055
2056```json
2057{
2058 "mode": "light"
2059}
2060```
2061
20623. Set the icon theme to system mode
2063
2064```json
2065{
2066 "mode": "system"
2067}
2068```
2069
2070### Dark
2071
2072- Description: The name of the dark icon theme.
2073- Setting: `dark`
2074- Default: `Zed (Default)`
2075
2076**Options**
2077
2078Run the `icon theme selector: toggle` action in the command palette to see a current list of valid icon themes names.
2079
2080### Light
2081
2082- Description: The name of the light icon theme.
2083- Setting: `light`
2084- Default: `Zed (Default)`
2085
2086**Options**
2087
2088Run the `icon theme selector: toggle` action in the command palette to see a current list of valid icon themes names.
2089
2090## Inlay hints
2091
2092- Description: Configuration for displaying extra text with hints in the editor.
2093- Setting: `inlay_hints`
2094- Default:
2095
2096```json
2097"inlay_hints": {
2098 "enabled": false,
2099 "show_type_hints": true,
2100 "show_parameter_hints": true,
2101 "show_other_hints": true,
2102 "show_background": false,
2103 "edit_debounce_ms": 700,
2104 "scroll_debounce_ms": 50,
2105 "toggle_on_modifiers_press": null
2106}
2107```
2108
2109**Options**
2110
2111Inlay hints querying consists of two parts: editor (client) and LSP server.
2112With 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.
2113At 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.
2114
2115The following languages have inlay hints preconfigured by Zed:
2116
2117- [Go](https://docs.zed.dev/languages/go)
2118- [Rust](https://docs.zed.dev/languages/rust)
2119- [Svelte](https://docs.zed.dev/languages/svelte)
2120- [Typescript](https://docs.zed.dev/languages/typescript)
2121
2122Use the `lsp` section for the server configuration. Examples are provided in the corresponding language documentation.
2123
2124Hints are not instantly queried in Zed, two kinds of debounces are used, either may be set to 0 to be disabled.
2125Settings-related hint updates are not debounced.
2126
2127All possible config values for `toggle_on_modifiers_press` are:
2128
2129```json
2130"inlay_hints": {
2131 "toggle_on_modifiers_press": {
2132 "control": true,
2133 "shift": true,
2134 "alt": true,
2135 "platform": true,
2136 "function": true
2137 }
2138}
2139```
2140
2141Unspecified values have a `false` value, hints won't be toggled if all the modifiers are `false` or not all the modifiers are pressed.
2142
2143## Journal
2144
2145- Description: Configuration for the journal.
2146- Setting: `journal`
2147- Default:
2148
2149```json
2150"journal": {
2151 "path": "~",
2152 "hour_format": "hour12"
2153}
2154```
2155
2156### Path
2157
2158- Description: The path of the directory where journal entries are stored.
2159- Setting: `path`
2160- Default: `~`
2161
2162**Options**
2163
2164`string` values
2165
2166### Hour Format
2167
2168- Description: The format to use for displaying hours in the journal.
2169- Setting: `hour_format`
2170- Default: `hour12`
2171
2172**Options**
2173
21741. 12-hour format:
2175
2176```json
2177{
2178 "hour_format": "hour12"
2179}
2180```
2181
21822. 24-hour format:
2183
2184```json
2185{
2186 "hour_format": "hour24"
2187}
2188```
2189
2190## Languages
2191
2192- Description: Configuration for specific languages.
2193- Setting: `languages`
2194- Default: `null`
2195
2196**Options**
2197
2198To override settings for a language, add an entry for that languages name to the `languages` value. Example:
2199
2200```json
2201"languages": {
2202 "C": {
2203 "format_on_save": "off",
2204 "preferred_line_length": 64,
2205 "soft_wrap": "preferred_line_length"
2206 },
2207 "JSON": {
2208 "tab_size": 4
2209 }
2210}
2211```
2212
2213The following settings can be overridden for each specific language:
2214
2215- [`enable_language_server`](#enable-language-server)
2216- [`ensure_final_newline_on_save`](#ensure-final-newline-on-save)
2217- [`format_on_save`](#format-on-save)
2218- [`formatter`](#formatter)
2219- [`hard_tabs`](#hard-tabs)
2220- [`preferred_line_length`](#preferred-line-length)
2221- [`remove_trailing_whitespace_on_save`](#remove-trailing-whitespace-on-save)
2222- [`show_edit_predictions`](#show-edit-predictions)
2223- [`show_whitespaces`](#show-whitespaces)
2224- [`soft_wrap`](#soft-wrap)
2225- [`tab_size`](#tab-size)
2226- [`use_autoclose`](#use-autoclose)
2227- [`always_treat_brackets_as_autoclosed`](#always-treat-brackets-as-autoclosed)
2228
2229These values take in the same options as the root-level settings with the same name.
2230
2231## Network Proxy
2232
2233- Description: Configure a network proxy for Zed.
2234- Setting: `proxy`
2235- Default: `null`
2236
2237**Options**
2238
2239The proxy setting must contain a URL to the proxy.
2240
2241The following URI schemes are supported:
2242
2243- `http`
2244- `https`
2245- `socks4` - SOCKS4 proxy with local DNS
2246- `socks4a` - SOCKS4 proxy with remote DNS
2247- `socks5` - SOCKS5 proxy with local DNS
2248- `socks5h` - SOCKS5 proxy with remote DNS
2249
2250`http` will be used when no scheme is specified.
2251
2252By 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`.
2253
2254For example, to set an `http` proxy, add the following to your settings:
2255
2256```json
2257{
2258 "proxy": "http://127.0.0.1:10809"
2259}
2260```
2261
2262Or to set a `socks5` proxy:
2263
2264```json
2265{
2266 "proxy": "socks5h://localhost:10808"
2267}
2268```
2269
2270If 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.
2271
2272## Preview tabs
2273
2274- Description:
2275 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. \
2276 There are several ways to convert a preview tab into a regular tab:
2277
2278 - Double-clicking on the file
2279 - Double-clicking on the tab header
2280 - Using the `project_panel::OpenPermanent` action
2281 - Editing the file
2282 - Dragging the file to a different pane
2283
2284- Setting: `preview_tabs`
2285- Default:
2286
2287```json
2288"preview_tabs": {
2289 "enabled": true,
2290 "enable_preview_from_file_finder": false,
2291 "enable_preview_from_code_navigation": false,
2292}
2293```
2294
2295### Enable preview from file finder
2296
2297- Description: Determines whether to open files in preview mode when selected from the file finder.
2298- Setting: `enable_preview_from_file_finder`
2299- Default: `false`
2300
2301**Options**
2302
2303`boolean` values
2304
2305### Enable preview from code navigation
2306
2307- Description: Determines whether a preview tab gets replaced when code navigation is used to navigate away from the tab.
2308- Setting: `enable_preview_from_code_navigation`
2309- Default: `false`
2310
2311**Options**
2312
2313`boolean` values
2314
2315## File Finder
2316
2317### File Icons
2318
2319- Description: Whether to show file icons in the file finder.
2320- Setting: `file_icons`
2321- Default: `true`
2322
2323### Modal Max Width
2324
2325- Description: Max-width of the file finder modal. It can take one of these values: `small`, `medium`, `large`, `xlarge`, and `full`.
2326- Setting: `modal_max_width`
2327- Default: `small`
2328
2329### Skip Focus For Active In Search
2330
2331- Description: Determines whether the file finder should skip focus for the active file in search results.
2332- Setting: `skip_focus_for_active_in_search`
2333- Default: `true`
2334
2335## Preferred Line Length
2336
2337- Description: The column at which to soft-wrap lines, for buffers where soft-wrap is enabled.
2338- Setting: `preferred_line_length`
2339- Default: `80`
2340
2341**Options**
2342
2343`integer` values
2344
2345## Projects Online By Default
2346
2347- Description: Whether or not to show the online projects view by default.
2348- Setting: `projects_online_by_default`
2349- Default: `true`
2350
2351**Options**
2352
2353`boolean` values
2354
2355## Remove Trailing Whitespace On Save
2356
2357- Description: Whether or not to remove any trailing whitespace from lines of a buffer before saving it.
2358- Setting: `remove_trailing_whitespace_on_save`
2359- Default: `true`
2360
2361**Options**
2362
2363`boolean` values
2364
2365## Search
2366
2367- Description: Search options to enable by default when opening new project and buffer searches.
2368- Setting: `search`
2369- Default:
2370
2371```json
2372"search": {
2373 "whole_word": false,
2374 "case_sensitive": false,
2375 "include_ignored": false,
2376 "regex": false
2377},
2378```
2379
2380## Seed Search Query From Cursor
2381
2382- Description: When to populate a new search's query based on the text under the cursor.
2383- Setting: `seed_search_query_from_cursor`
2384- Default: `always`
2385
2386**Options**
2387
23881. `always` always populate the search query with the word under the cursor
23892. `selection` only populate the search query when there is text selected
23903. `never` never populate the search query
2391
2392## Use Smartcase Search
2393
2394- 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. \
2395 This applies to both in-file searches and project-wide searches.
2396- Setting: `use_smartcase_search`
2397- Default: `false`
2398
2399**Options**
2400
2401`boolean` values
2402
2403Examples:
2404
2405- Searching for "function" would match "function", "Function", "FUNCTION", etc.
2406- Searching for "Function" would only match "Function", not "function" or "FUNCTION"
2407
2408## Show Call Status Icon
2409
2410- Description: Whether or not to show the call status icon in the status bar.
2411- Setting: `show_call_status_icon`
2412- Default: `true`
2413
2414**Options**
2415
2416`boolean` values
2417
2418## Completions
2419
2420- Description: Controls how completions are processed for this language.
2421- Setting: `completions`
2422- Default:
2423
2424```json
2425{
2426 "completions": {
2427 "words": "fallback",
2428 "lsp": true,
2429 "lsp_fetch_timeout_ms": 0,
2430 "lsp_insert_mode": "replace_suffix"
2431 }
2432}
2433```
2434
2435### Words
2436
2437- Description: Controls how words are completed. For large documents, not all words may be fetched for completion.
2438- Setting: `words`
2439- Default: `fallback`
2440
2441**Options**
2442
24431. `enabled` - Always fetch document's words for completions along with LSP completions
24442. `fallback` - Only if LSP response errors or times out, use document's words to show completions
24453. `disabled` - Never fetch or complete document's words for completions (word-based completions can still be queried via a separate action)
2446
2447### LSP
2448
2449- Description: Whether to fetch LSP completions or not.
2450- Setting: `lsp`
2451- Default: `true`
2452
2453**Options**
2454
2455`boolean` values
2456
2457### LSP Fetch Timeout (ms)
2458
2459- Description: When fetching LSP completions, determines how long to wait for a response of a particular server. When set to 0, waits indefinitely.
2460- Setting: `lsp_fetch_timeout_ms`
2461- Default: `0`
2462
2463**Options**
2464
2465`integer` values representing milliseconds
2466
2467### LSP Insert Mode
2468
2469- Description: Controls what range to replace when accepting LSP completions.
2470- Setting: `lsp_insert_mode`
2471- Default: `replace_suffix`
2472
2473**Options**
2474
24751. `insert` - Replaces text before the cursor, using the `insert` range described in the LSP specification
24762. `replace` - Replaces text before and after the cursor, using the `replace` range described in the LSP specification
24773. `replace_subsequence` - Behaves like `"replace"` if the text that would be replaced is a subsequence of the completion text, and like `"insert"` otherwise
24784. `replace_suffix` - Behaves like `"replace"` if the text after the cursor is a suffix of the completion, and like `"insert"` otherwise
2479
2480## Show Completions On Input
2481
2482- Description: Whether or not to show completions as you type.
2483- Setting: `show_completions_on_input`
2484- Default: `true`
2485
2486**Options**
2487
2488`boolean` values
2489
2490## Show Completion Documentation
2491
2492- Description: Whether to display inline and alongside documentation for items in the completions menu.
2493- Setting: `show_completion_documentation`
2494- Default: `true`
2495
2496**Options**
2497
2498`boolean` values
2499
2500## Show Edit Predictions
2501
2502- Description: Whether to show edit predictions as you type or manually by triggering `editor::ShowEditPrediction`.
2503- Setting: `show_edit_predictions`
2504- Default: `true`
2505
2506**Options**
2507
2508`boolean` values
2509
2510## Show Whitespaces
2511
2512- Description: Whether or not to render whitespace characters in the editor.
2513- Setting: `show_whitespaces`
2514- Default: `selection`
2515
2516**Options**
2517
25181. `all`
25192. `selection`
25203. `none`
25214. `boundary`
2522
2523## Soft Wrap
2524
2525- Description: Whether or not to automatically wrap lines of text to fit editor / preferred width.
2526- Setting: `soft_wrap`
2527- Default: `none`
2528
2529**Options**
2530
25311. `none` to avoid wrapping generally, unless the line is too long
25322. `prefer_line` (deprecated, same as `none`)
25333. `editor_width` to wrap lines that overflow the editor width
25344. `preferred_line_length` to wrap lines that overflow `preferred_line_length` config value
25355. `bounded` to wrap lines at the minimum of `editor_width` and `preferred_line_length`
2536
2537## Wrap Guides (Vertical Rulers)
2538
2539- Description: Where to display vertical rulers as wrap-guides. Disable by setting `show_wrap_guides` to `false`.
2540- Setting: `wrap_guides`
2541- Default: []
2542
2543**Options**
2544
2545List of `integer` column numbers
2546
2547## Tab Size
2548
2549- Description: The number of spaces to use for each tab character.
2550- Setting: `tab_size`
2551- Default: `4`
2552
2553**Options**
2554
2555`integer` values
2556
2557## Telemetry
2558
2559- Description: Control what info is collected by Zed.
2560- Setting: `telemetry`
2561- Default:
2562
2563```json
2564"telemetry": {
2565 "diagnostics": true,
2566 "metrics": true
2567},
2568```
2569
2570**Options**
2571
2572### Diagnostics
2573
2574- Description: Setting for sending debug-related data, such as crash reports.
2575- Setting: `diagnostics`
2576- Default: `true`
2577
2578**Options**
2579
2580`boolean` values
2581
2582### Metrics
2583
2584- Description: Setting for sending anonymized usage data, such what languages you're using Zed with.
2585- Setting: `metrics`
2586- Default: `true`
2587
2588**Options**
2589
2590`boolean` values
2591
2592## Terminal
2593
2594- Description: Configuration for the terminal.
2595- Setting: `terminal`
2596- Default:
2597
2598```json
2599{
2600 "terminal": {
2601 "alternate_scroll": "off",
2602 "blinking": "terminal_controlled",
2603 "copy_on_select": false,
2604 "keep_selection_on_copy": false,
2605 "dock": "bottom",
2606 "default_width": 640,
2607 "default_height": 320,
2608 "detect_venv": {
2609 "on": {
2610 "directories": [".env", "env", ".venv", "venv"],
2611 "activate_script": "default"
2612 }
2613 },
2614 "env": {},
2615 "font_family": null,
2616 "font_features": null,
2617 "font_size": null,
2618 "line_height": "comfortable",
2619 "minimum_contrast": 45,
2620 "option_as_meta": false,
2621 "button": true,
2622 "shell": "system",
2623 "toolbar": {
2624 "breadcrumbs": true
2625 },
2626 "working_directory": "current_project_directory",
2627 "scrollbar": {
2628 "show": null
2629 }
2630 }
2631}
2632```
2633
2634### Terminal: Dock
2635
2636- Description: Control the position of the dock
2637- Setting: `dock`
2638- Default: `bottom`
2639
2640**Options**
2641
2642`"bottom"`, `"left"` or `"right"`
2643
2644### Terminal: Alternate Scroll
2645
2646- 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.
2647- Setting: `alternate_scroll`
2648- Default: `off`
2649
2650**Options**
2651
26521. Default alternate scroll mode to off
2653
2654```json
2655{
2656 "terminal": {
2657 "alternate_scroll": "off"
2658 }
2659}
2660```
2661
26622. Default alternate scroll mode to on
2663
2664```json
2665{
2666 "terminal": {
2667 "alternate_scroll": "on"
2668 }
2669}
2670```
2671
2672### Terminal: Blinking
2673
2674- Description: Set the cursor blinking behavior in the terminal
2675- Setting: `blinking`
2676- Default: `terminal_controlled`
2677
2678**Options**
2679
26801. Never blink the cursor, ignore the terminal mode
2681
2682```json
2683{
2684 "terminal": {
2685 "blinking": "off"
2686 }
2687}
2688```
2689
26902. Default the cursor blink to off, but allow the terminal to turn blinking on
2691
2692```json
2693{
2694 "terminal": {
2695 "blinking": "terminal_controlled"
2696 }
2697}
2698```
2699
27003. Always blink the cursor, ignore the terminal mode
2701
2702```json
2703{
2704 "terminal": {
2705 "blinking": "on"
2706 }
2707}
2708```
2709
2710### Terminal: Copy On Select
2711
2712- Description: Whether or not selecting text in the terminal will automatically copy to the system clipboard.
2713- Setting: `copy_on_select`
2714- Default: `false`
2715
2716**Options**
2717
2718`boolean` values
2719
2720**Example**
2721
2722```json
2723{
2724 "terminal": {
2725 "copy_on_select": true
2726 }
2727}
2728```
2729
2730### Terminal: Cursor Shape
2731
2732- Description: Whether or not selecting text in the terminal will automatically copy to the system clipboard.
2733- Setting: `cursor_shape`
2734- Default: `null` (defaults to block)
2735
2736**Options**
2737
27381. A block that surrounds the following character
2739
2740```json
2741{
2742 "terminal": {
2743 "cursor_shape": "block"
2744 }
2745}
2746```
2747
27482. A vertical bar
2749
2750```json
2751{
2752 "terminal": {
2753 "cursor_shape": "bar"
2754 }
2755}
2756```
2757
27583. An underline / underscore that runs along the following character
2759
2760```json
2761{
2762 "terminal": {
2763 "cursor_shape": "underline"
2764 }
2765}
2766```
2767
27684. A box drawn around the following character
2769
2770```json
2771{
2772 "terminal": {
2773 "cursor_shape": "hollow"
2774 }
2775}
2776```
2777
2778### Terminal: Keep Selection On Copy
2779
2780- Description: Whether or not to keep the selection in the terminal after copying text.
2781- Setting: `keep_selection_on_copy`
2782- Default: `false`
2783
2784**Options**
2785
2786`boolean` values
2787
2788**Example**
2789
2790```json
2791{
2792 "terminal": {
2793 "keep_selection_on_copy": true
2794 }
2795}
2796```
2797
2798### Terminal: Env
2799
2800- 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
2801- Setting: `env`
2802- Default: `{}`
2803
2804**Example**
2805
2806```json
2807{
2808 "terminal": {
2809 "env": {
2810 "ZED": "1",
2811 "KEY": "value1:value2"
2812 }
2813 }
2814}
2815```
2816
2817### Terminal: Font Size
2818
2819- Description: What font size to use for the terminal. When not set defaults to matching the editor's font size
2820- Setting: `font_size`
2821- Default: `null`
2822
2823**Options**
2824
2825`integer` values
2826
2827```json
2828{
2829 "terminal": {
2830 "font_size": 15
2831 }
2832}
2833```
2834
2835### Terminal: Font Family
2836
2837- Description: What font to use for the terminal. When not set, defaults to matching the editor's font.
2838- Setting: `font_family`
2839- Default: `null`
2840
2841**Options**
2842
2843The name of any font family installed on the user's system
2844
2845```json
2846{
2847 "terminal": {
2848 "font_family": "Berkeley Mono"
2849 }
2850}
2851```
2852
2853### Terminal: Font Features
2854
2855- Description: What font features to use for the terminal. When not set, defaults to matching the editor's font features.
2856- Setting: `font_features`
2857- Default: `null`
2858- Platform: macOS and Windows.
2859
2860**Options**
2861
2862See Buffer Font Features
2863
2864```json
2865{
2866 "terminal": {
2867 "font_features": {
2868 "calt": false
2869 // See Buffer Font Features for more features
2870 }
2871 }
2872}
2873```
2874
2875### Terminal: Line Height
2876
2877- Description: Set the terminal's line height.
2878- Setting: `line_height`
2879- Default: `comfortable`
2880
2881**Options**
2882
28831. Use a line height that's `comfortable` for reading, 1.618. (default)
2884
2885```json
2886{
2887 "terminal": {
2888 "line_height": "comfortable"
2889 }
2890}
2891```
2892
28932. Use a `standard` line height, 1.3. This option is useful for TUIs, particularly if they use box characters
2894
2895```json
2896{
2897 "terminal": {
2898 "line_height": "standard"
2899 }
2900}
2901```
2902
29033. Use a custom line height.
2904
2905```json
2906{
2907 "terminal": {
2908 "line_height": {
2909 "custom": 2
2910 }
2911 }
2912}
2913```
2914
2915### Terminal: Minimum Contrast
2916
2917- 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.
2918- Setting: `minimum_contrast`
2919- Default: `45`
2920
2921**Options**
2922
2923`integer` values from 0 to 106. Common recommended values:
2924
2925- `0`: No contrast adjustment
2926- `45`: Minimum for large fluent text (default)
2927- `60`: Minimum for other content text
2928- `75`: Minimum for body text
2929- `90`: Preferred for body text
2930
2931```json
2932{
2933 "terminal": {
2934 "minimum_contrast": 45
2935 }
2936}
2937```
2938
2939### Terminal: Option As Meta
2940
2941- Description: Re-interprets the option keys to act like a 'meta' key, like in Emacs.
2942- Setting: `option_as_meta`
2943- Default: `false`
2944
2945**Options**
2946
2947`boolean` values
2948
2949```json
2950{
2951 "terminal": {
2952 "option_as_meta": true
2953 }
2954}
2955```
2956
2957### Terminal: Shell
2958
2959- Description: What shell to use when launching the terminal.
2960- Setting: `shell`
2961- Default: `system`
2962
2963**Options**
2964
29651. Use the system's default terminal configuration (usually the `/etc/passwd` file).
2966
2967```json
2968{
2969 "terminal": {
2970 "shell": "system"
2971 }
2972}
2973```
2974
29752. A program to launch:
2976
2977```json
2978{
2979 "terminal": {
2980 "shell": {
2981 "program": "sh"
2982 }
2983 }
2984}
2985```
2986
29873. A program with arguments:
2988
2989```json
2990{
2991 "terminal": {
2992 "shell": {
2993 "with_arguments": {
2994 "program": "/bin/bash",
2995 "args": ["--login"]
2996 }
2997 }
2998 }
2999}
3000```
3001
3002## Terminal: Detect Virtual Environments {#terminal-detect_venv}
3003
3004- 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.
3005- Setting: `detect_venv`
3006- Default:
3007
3008```json
3009{
3010 "terminal": {
3011 "detect_venv": {
3012 "on": {
3013 // Default directories to search for virtual environments, relative
3014 // to the current working directory. We recommend overriding this
3015 // in your project's settings, rather than globally.
3016 "directories": [".env", "env", ".venv", "venv"],
3017 // Can also be `csh`, `fish`, and `nushell`
3018 "activate_script": "default"
3019 }
3020 }
3021 }
3022}
3023```
3024
3025Disable with:
3026
3027```json
3028{
3029 "terminal": {
3030 "detect_venv": "off"
3031 }
3032}
3033```
3034
3035## Terminal: Toolbar
3036
3037- Description: Whether or not to show various elements in the terminal toolbar.
3038- Setting: `toolbar`
3039- Default:
3040
3041```json
3042{
3043 "terminal": {
3044 "toolbar": {
3045 "breadcrumbs": true
3046 }
3047 }
3048}
3049```
3050
3051**Options**
3052
3053At the moment, only the `breadcrumbs` option is available, it controls displaying of the terminal title that can be changed via `PROMPT_COMMAND`.
3054
3055If the terminal title is empty, the breadcrumbs won't be shown.
3056
3057The shell running in the terminal needs to be configured to emit the title.
3058
3059Example command to set the title: `echo -e "\e]2;New Title\007";`
3060
3061### Terminal: Button
3062
3063- Description: Control to show or hide the terminal button in the status bar
3064- Setting: `button`
3065- Default: `true`
3066
3067**Options**
3068
3069`boolean` values
3070
3071```json
3072{
3073 "terminal": {
3074 "button": false
3075 }
3076}
3077```
3078
3079### Terminal: Working Directory
3080
3081- Description: What working directory to use when launching the terminal.
3082- Setting: `working_directory`
3083- Default: `"current_project_directory"`
3084
3085**Options**
3086
30871. Use the current file's project directory. Will Fallback to the first project directory strategy if unsuccessful
3088
3089```json
3090{
3091 "terminal": {
3092 "working_directory": "current_project_directory"
3093 }
3094}
3095```
3096
30972. Use the first project in this workspace's directory. Will fallback to using this platform's home directory.
3098
3099```json
3100{
3101 "terminal": {
3102 "working_directory": "first_project_directory"
3103 }
3104}
3105```
3106
31073. Always use this platform's home directory (if we can find it)
3108
3109```json
3110{
3111 "terminal": {
3112 "working_directory": "always_home"
3113 }
3114}
3115```
3116
31174. 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.
3118
3119```json
3120{
3121 "terminal": {
3122 "working_directory": {
3123 "always": {
3124 "directory": "~/zed/projects/"
3125 }
3126 }
3127 }
3128}
3129```
3130
3131## Theme
3132
3133- 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.
3134- Setting: `theme`
3135- Default: `One Dark`
3136
3137### Theme Object
3138
3139- Description: Specify the theme using an object that includes the `mode`, `dark`, and `light` themes.
3140- Setting: `theme`
3141- Default:
3142
3143```json
3144"theme": {
3145 "mode": "system",
3146 "dark": "One Dark",
3147 "light": "One Light"
3148},
3149```
3150
3151### Mode
3152
3153- Description: Specify theme mode.
3154- Setting: `mode`
3155- Default: `system`
3156
3157**Options**
3158
31591. Set the theme to dark mode
3160
3161```json
3162{
3163 "mode": "dark"
3164}
3165```
3166
31672. Set the theme to light mode
3168
3169```json
3170{
3171 "mode": "light"
3172}
3173```
3174
31753. Set the theme to system mode
3176
3177```json
3178{
3179 "mode": "system"
3180}
3181```
3182
3183### Dark
3184
3185- Description: The name of the dark Zed theme to use for the UI.
3186- Setting: `dark`
3187- Default: `One Dark`
3188
3189**Options**
3190
3191Run the `theme selector: toggle` action in the command palette to see a current list of valid themes names.
3192
3193### Light
3194
3195- Description: The name of the light Zed theme to use for the UI.
3196- Setting: `light`
3197- Default: `One Light`
3198
3199**Options**
3200
3201Run the `theme selector: toggle` action in the command palette to see a current list of valid themes names.
3202
3203## Vim
3204
3205- Description: Whether or not to enable vim mode. See the [Vim documentation](./vim.md) for more details on configuration.
3206- Setting: `vim_mode`
3207- Default: `false`
3208
3209## Helix Mode
3210
3211- Description: Whether or not to enable Helix mode. Enabling `helix_mode` also enables `vim_mode`. See the [Helix documentation](./helix.md) for more details.
3212- Setting: `helix_mode`
3213- Default: `false`
3214
3215## Project Panel
3216
3217- Description: Customize project panel
3218- Setting: `project_panel`
3219- Default:
3220
3221```json
3222{
3223 "project_panel": {
3224 "button": true,
3225 "default_width": 240,
3226 "dock": "left",
3227 "entry_spacing": "comfortable",
3228 "file_icons": true,
3229 "folder_icons": true,
3230 "git_status": true,
3231 "indent_size": 20,
3232 "auto_reveal_entries": true,
3233 "auto_fold_dirs": true,
3234 "scrollbar": {
3235 "show": null
3236 },
3237 "show_diagnostics": "all",
3238 "indent_guides": {
3239 "show": "always"
3240 },
3241 "hide_root": false,
3242 "starts_open": true
3243 }
3244}
3245```
3246
3247### Dock
3248
3249- Description: Control the position of the dock
3250- Setting: `dock`
3251- Default: `left`
3252
3253**Options**
3254
32551. Default dock position to left
3256
3257```json
3258{
3259 "dock": "left"
3260}
3261```
3262
32632. Default dock position to right
3264
3265```json
3266{
3267 "dock": "right"
3268}
3269```
3270
3271### Entry Spacing
3272
3273- Description: Spacing between worktree entries
3274- Setting: `entry_spacing`
3275- Default: `comfortable`
3276
3277**Options**
3278
32791. Comfortable entry spacing
3280
3281```json
3282{
3283 "entry_spacing": "comfortable"
3284}
3285```
3286
32872. Standard entry spacing
3288
3289```json
3290{
3291 "entry_spacing": "standard"
3292}
3293```
3294
3295### Git Status
3296
3297- Description: Indicates newly created and updated files
3298- Setting: `git_status`
3299- Default: `true`
3300
3301**Options**
3302
33031. Default enable git status
3304
3305```json
3306{
3307 "git_status": true
3308}
3309```
3310
33112. Default disable git status
3312
3313```json
3314{
3315 "git_status": false
3316}
3317```
3318
3319### Default Width
3320
3321- Description: Customize default width taken by project panel
3322- Setting: `default_width`
3323- Default: `240`
3324
3325**Options**
3326
3327`float` values
3328
3329### Auto Reveal Entries
3330
3331- Description: Whether to reveal it in the project panel automatically, when a corresponding project entry becomes active. Gitignored entries are never auto revealed.
3332- Setting: `auto_reveal_entries`
3333- Default: `true`
3334
3335**Options**
3336
33371. Enable auto reveal entries
3338
3339```json
3340{
3341 "auto_reveal_entries": true
3342}
3343```
3344
33452. Disable auto reveal entries
3346
3347```json
3348{
3349 "auto_reveal_entries": false
3350}
3351```
3352
3353### Auto Fold Dirs
3354
3355- Description: Whether to fold directories automatically when directory has only one directory inside.
3356- Setting: `auto_fold_dirs`
3357- Default: `true`
3358
3359**Options**
3360
33611. Enable auto fold dirs
3362
3363```json
3364{
3365 "auto_fold_dirs": true
3366}
3367```
3368
33692. Disable auto fold dirs
3370
3371```json
3372{
3373 "auto_fold_dirs": false
3374}
3375```
3376
3377### Indent Size
3378
3379- Description: Amount of indentation (in pixels) for nested items.
3380- Setting: `indent_size`
3381- Default: `20`
3382
3383### Indent Guides: Show
3384
3385- Description: Whether to show indent guides in the project panel.
3386- Setting: `indent_guides`
3387- Default:
3388
3389```json
3390"indent_guides": {
3391 "show": "always"
3392}
3393```
3394
3395**Options**
3396
33971. Show indent guides in the project panel
3398
3399```json
3400{
3401 "indent_guides": {
3402 "show": "always"
3403 }
3404}
3405```
3406
34072. Hide indent guides in the project panel
3408
3409```json
3410{
3411 "indent_guides": {
3412 "show": "never"
3413 }
3414}
3415```
3416
3417### Scrollbar: Show
3418
3419- 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.
3420- Setting: `scrollbar`
3421- Default:
3422
3423```json
3424"scrollbar": {
3425 "show": null
3426}
3427```
3428
3429**Options**
3430
34311. Show scrollbar in the project panel
3432
3433```json
3434{
3435 "scrollbar": {
3436 "show": "always"
3437 }
3438}
3439```
3440
34412. Hide scrollbar in the project panel
3442
3443```json
3444{
3445 "scrollbar": {
3446 "show": "never"
3447 }
3448}
3449```
3450
3451## Agent
3452
3453Visit [the Configuration page](./ai/configuration.md) under the AI section to learn more about all the agent-related settings.
3454
3455## Outline Panel
3456
3457- Description: Customize outline Panel
3458- Setting: `outline_panel`
3459- Default:
3460
3461```json
3462"outline_panel": {
3463 "button": true,
3464 "default_width": 300,
3465 "dock": "left",
3466 "file_icons": true,
3467 "folder_icons": true,
3468 "git_status": true,
3469 "indent_size": 20,
3470 "auto_reveal_entries": true,
3471 "auto_fold_dirs": true,
3472 "indent_guides": {
3473 "show": "always"
3474 },
3475 "scrollbar": {
3476 "show": null
3477 }
3478}
3479```
3480
3481## Calls
3482
3483- Description: Customize behavior when participating in a call
3484- Setting: `calls`
3485- Default:
3486
3487```json
3488"calls": {
3489 // Join calls with the microphone live by default
3490 "mute_on_join": false,
3491 // Share your project when you are the first to join a channel
3492 "share_on_join": false
3493},
3494```
3495
3496## Unnecessary Code Fade
3497
3498- Description: How much to fade out unused code.
3499- Setting: `unnecessary_code_fade`
3500- Default: `0.3`
3501
3502**Options**
3503
3504Float values between `0.0` and `0.9`, where:
3505
3506- `0.0` means no fading (unused code looks the same as used code)
3507- `0.9` means maximum fading (unused code is very faint but still visible)
3508
3509**Example**
3510
3511```json
3512{
3513 "unnecessary_code_fade": 0.5
3514}
3515```
3516
3517## UI Font Family
3518
3519- Description: The name of the font to use for text in the UI.
3520- Setting: `ui_font_family`
3521- Default: `.ZedSans`. This currently aliases to [IBM Plex](https://www.ibm.com/plex/).
3522
3523**Options**
3524
3525The 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).
3526
3527## UI Font Features
3528
3529- Description: The OpenType features to enable for text in the UI.
3530- Setting: `ui_font_features`
3531- Default:
3532
3533```json
3534"ui_font_features": {
3535 "calt": false
3536}
3537```
3538
3539- Platform: macOS and Windows.
3540
3541**Options**
3542
3543Zed supports all OpenType features that can be enabled or disabled for a given UI font, as well as setting values for font features.
3544
3545For example, to disable font ligatures, add the following to your settings:
3546
3547```json
3548{
3549 "ui_font_features": {
3550 "calt": false
3551 }
3552}
3553```
3554
3555You can also set other OpenType features, like setting `cv01` to `7`:
3556
3557```json
3558{
3559 "ui_font_features": {
3560 "cv01": 7
3561 }
3562}
3563```
3564
3565## UI Font Fallbacks
3566
3567- Description: The font fallbacks to use for text in the UI.
3568- Setting: `ui_font_fallbacks`
3569- Default: `null`
3570- Platform: macOS and Windows.
3571
3572**Options**
3573
3574For example, to use `Nerd Font` as a fallback, add the following to your settings:
3575
3576```json
3577{
3578 "ui_font_fallbacks": ["Nerd Font"]
3579}
3580```
3581
3582## UI Font Size
3583
3584- Description: The default font size for text in the UI.
3585- Setting: `ui_font_size`
3586- Default: `16`
3587
3588**Options**
3589
3590`integer` values from `6` to `100` pixels (inclusive)
3591
3592## UI Font Weight
3593
3594- Description: The default font weight for text in the UI.
3595- Setting: `ui_font_weight`
3596- Default: `400`
3597
3598**Options**
3599
3600`integer` values between `100` and `900`
3601
3602## An example configuration:
3603
3604```json
3605// ~/.config/zed/settings.json
3606{
3607 "theme": "cave-light",
3608 "tab_size": 2,
3609 "preferred_line_length": 80,
3610 "soft_wrap": "none",
3611
3612 "buffer_font_size": 18,
3613 "buffer_font_family": ".ZedMono",
3614
3615 "autosave": "on_focus_change",
3616 "format_on_save": "off",
3617 "vim_mode": false,
3618 "projects_online_by_default": true,
3619 "terminal": {
3620 "font_family": "FiraCode Nerd Font Mono",
3621 "blinking": "off"
3622 },
3623 "languages": {
3624 "C": {
3625 "format_on_save": "language_server",
3626 "preferred_line_length": 64,
3627 "soft_wrap": "preferred_line_length"
3628 }
3629 }
3630}
3631```