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 Editor
8
9You can browse through many of the supported settings via the Settings Editor, which can be opened with the {#kb zed::OpenSettings} keybinding, or through the `zed: open settings` action in the command palette. Through it, you can customize your local, user settings as well as project settings.
10
11> Note that not all settings that Zed supports are available through the Settings Editor yet.
12> Some more intricate ones, such as language formatters, can only be changed through the JSON settings file {#kb zed::OpenSettingsFile}.
13
14## User Settings File
15
16<!--
17TBD: Settings files. Rewrite with "remote settings" in mind (e.g. `local settings` on the remote host).
18Consider renaming `zed: Open Local Settings` to `zed: Open Project Settings`.
19
20TBD: 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.
21-->
22
23Your settings JSON file can be opened with {#kb zed::OpenSettingsFile}.
24By 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.
25
26Whatever you have added to your user settings file gets merged with any local configuration inside your projects.
27
28### Default Settings
29
30In the Settings Editor, the values you see set are the default ones.
31You can also verify them in JSON by running {#action zed::OpenDefaultSettings} from the command palette.
32
33Extensions that provide language servers may also provide default settings for those language servers.
34
35## Project Settings File
36
37Similarly to user files, you can open your project settings file by running {#action zed::OpenProjectSettings} from the command palette.
38This will create a `.zed` directory containing`.zed/settings.json`.
39
40Although most projects will only need one settings file at the root, you can add more local settings files for subdirectories as needed.
41Not all settings can be set in local files, just those that impact the behavior of the editor and language tooling.
42For example you can set `tab_size`, `formatter` etc. but not `theme`, `vim_mode` and similar.
43
44The syntax for configuration files is a super-set of JSON that allows `//` comments.
45
46## Per-release Channel Overrides
47
48Zed reads the same `settings.json` across all release channels (Stable, Preview or Nightly).
49However, you can scope overrides to a specific channel by adding top-level `stable`, `preview`, `nightly` or `dev` objects.
50They are merged into the base configuration with settings from these keys taking precedence upon launching the specified build. For example:
51
52```json [settings]
53{
54 "theme": "sunset",
55 "vim_mode": false,
56 "nightly": {
57 "theme": "cave-light",
58 "vim_mode": true
59 },
60 "preview": {
61 "theme": "zed-dark"
62 }
63}
64```
65
66With this configuration, Stable keeps all base preferences, Preview switches to `zed-dark`, and Nightly enables Vim mode with a different theme.
67
68Changing settings in the Settings Editorwill always apply the change across all channels.
69
70# Settings
71
72Find below an extensive run-through of many supported settings by Zed.
73
74## Active Pane Modifiers
75
76- Description: Styling settings applied to the active pane.
77- Setting: `active_pane_modifiers`
78- Default:
79
80```json [settings]
81{
82 "active_pane_modifiers": {
83 "border_size": 0.0,
84 "inactive_opacity": 1.0
85 }
86}
87```
88
89### Border size
90
91- 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.
92- Setting: `border_size`
93- Default: `0.0`
94
95**Options**
96
97Non-negative `float` values
98
99### Inactive Opacity
100
101- 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.
102- Setting: `inactive_opacity`
103- Default: `1.0`
104
105**Options**
106
107`float` values
108
109## Bottom Dock Layout
110
111- Description: Control the layout of the bottom dock, relative to the left and right docks.
112- Setting: `bottom_dock_layout`
113- Default: `"contained"`
114
115**Options**
116
1171. Contain the bottom dock, giving the full height of the window to the left and right docks.
118
119```json [settings]
120{
121 "bottom_dock_layout": "contained"
122}
123```
124
1252. Give the bottom dock the full width of the window, truncating the left and right docks.
126
127```json [settings]
128{
129 "bottom_dock_layout": "full"
130}
131```
132
1333. Left align the bottom dock, truncating the left dock and giving the right dock the full height of the window.
134
135```json [settings]
136{
137 "bottom_dock_layout": "left_aligned"
138}
139```
140
1414. Right align the bottom dock, giving the left dock the full height of the window and truncating the right dock.
142
143```json [settings]
144{
145 "bottom_dock_layout": "right_aligned"
146}
147```
148
149## Agent Font Size
150
151- Description: The font size for text in the agent panel. Inherits the UI font size if unset.
152- Setting: `agent_font_size`
153- Default: `null`
154
155**Options**
156
157`integer` values from `6` to `100` pixels (inclusive)
158
159## Allow Rewrap
160
161- Description: Controls where the {#action editor::Rewrap} action is allowed in the current language scope
162- Setting: `allow_rewrap`
163- Default: `"in_comments"`
164
165**Options**
166
1671. Allow rewrap in comments only:
168
169```json [settings]
170{
171 "allow_rewrap": "in_comments"
172}
173```
174
1752. Allow rewrap in selections only:
176
177```json [settings]
178{
179 "allow_rewrap": "in_selections"
180}
181```
182
1833. Allow rewrap anywhere:
184
185```json [settings]
186{
187 "allow_rewrap": "anywhere"
188}
189```
190
191Note: This setting has no effect in Vim mode, as rewrap is already allowed everywhere.
192
193## Auto Indent
194
195- Description: Whether indentation should be adjusted based on the context whilst typing. This can be specified on a per-language basis.
196- Setting: `auto_indent`
197- Default: `true`
198
199**Options**
200
201`boolean` values
202
203## Auto Indent On Paste
204
205- Description: Whether indentation of pasted content should be adjusted based on the context
206- Setting: `auto_indent_on_paste`
207- Default: `true`
208
209**Options**
210
211`boolean` values
212
213## Auto Install extensions
214
215- Description: Define extensions to be autoinstalled or never be installed.
216- Setting: `auto_install_extension`
217- Default: `{ "html": true }`
218
219**Options**
220
221You can find the names of your currently installed extensions by listing the subfolders under the [extension installation location](./extensions/installing-extensions.md#installation-location):
222
223On macOS:
224
225```sh
226ls ~/Library/Application\ Support/Zed/extensions/installed/
227```
228
229On Linux:
230
231```sh
232ls ~/.local/share/zed/extensions/installed
233```
234
235Define extensions which should be installed (`true`) or never installed (`false`).
236
237```json [settings]
238{
239 "auto_install_extensions": {
240 "html": true,
241 "dockerfile": true,
242 "docker-compose": false
243 }
244}
245```
246
247## Autosave
248
249- Description: When to automatically save edited buffers.
250- Setting: `autosave`
251- Default: `off`
252
253**Options**
254
2551. To disable autosave, set it to `off`:
256
257```json [settings]
258{
259 "autosave": "off"
260}
261```
262
2632. To autosave when focus changes, use `on_focus_change`:
264
265```json [settings]
266{
267 "autosave": "on_focus_change"
268}
269```
270
2713. To autosave when the active window changes, use `on_window_change`:
272
273```json [settings]
274{
275 "autosave": "on_window_change"
276}
277```
278
2794. To autosave after an inactivity period, use `after_delay`:
280
281```json [settings]
282{
283 "autosave": {
284 "after_delay": {
285 "milliseconds": 1000
286 }
287 }
288}
289```
290
291Note that a save will be triggered when an unsaved tab is closed, even if this is earlier than the configured inactivity period.
292
293## Autoscroll on Clicks
294
295- Description: Whether to scroll when clicking near the edge of the visible text area.
296- Setting: `autoscroll_on_clicks`
297- Default: `false`
298
299**Options**
300
301`boolean` values
302
303## Auto Signature Help
304
305- Description: Show method signatures in the editor, when inside parentheses
306- Setting: `auto_signature_help`
307- Default: `false`
308
309**Options**
310
311`boolean` values
312
313### Show Signature Help After Edits
314
315- Description: Whether to show the signature help after completion or a bracket pair inserted. If `auto_signature_help` is enabled, this setting will be treated as enabled also.
316- Setting: `show_signature_help_after_edits`
317- Default: `false`
318
319**Options**
320
321`boolean` values
322
323## Auto Update
324
325- Description: Whether or not to automatically check for updates.
326- Setting: `auto_update`
327- Default: `true`
328
329**Options**
330
331`boolean` values
332
333## Base Keymap
334
335- Description: Base key bindings scheme. Base keymaps can be overridden with user keymaps.
336- Setting: `base_keymap`
337- Default: `VSCode`
338
339**Options**
340
3411. VS Code
342
343```json [settings]
344{
345 "base_keymap": "VSCode"
346}
347```
348
3492. Atom
350
351```json [settings]
352{
353 "base_keymap": "Atom"
354}
355```
356
3573. JetBrains
358
359```json [settings]
360{
361 "base_keymap": "JetBrains"
362}
363```
364
3654. None
366
367```json [settings]
368{
369 "base_keymap": "None"
370}
371```
372
3735. Sublime Text
374
375```json [settings]
376{
377 "base_keymap": "SublimeText"
378}
379```
380
3816. TextMate
382
383```json [settings]
384{
385 "base_keymap": "TextMate"
386}
387```
388
389## Buffer Font Family
390
391- Description: The name of a font to use for rendering text in the editor.
392- Setting: `buffer_font_family`
393- Default: `.ZedMono`. This currently aliases to [Lilex](https://lilex.myrt.co).
394
395**Options**
396
397The name of any font family installed on the user's system, or `".ZedMono"`.
398
399## Buffer Font Features
400
401- Description: The OpenType features to enable for text in the editor.
402- Setting: `buffer_font_features`
403- Default: `null`
404- Platform: macOS and Windows.
405
406**Options**
407
408Zed 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.
409
410For example, to disable font ligatures, add the following to your settings:
411
412```json [settings]
413{
414 "buffer_font_features": {
415 "calt": false
416 }
417}
418```
419
420You can also set other OpenType features, like setting `cv01` to `7`:
421
422```json [settings]
423{
424 "buffer_font_features": {
425 "cv01": 7
426 }
427}
428```
429
430## Buffer Font Fallbacks
431
432- Description: Set the buffer text's font fallbacks, this will be merged with the platform's default fallbacks.
433- Setting: `buffer_font_fallbacks`
434- Default: `null`
435- Platform: macOS and Windows.
436
437**Options**
438
439For example, to use `Nerd Font` as a fallback, add the following to your settings:
440
441```json [settings]
442{
443 "buffer_font_fallbacks": ["Nerd Font"]
444}
445```
446
447## Buffer Font Size
448
449- Description: The default font size for text in the editor.
450- Setting: `buffer_font_size`
451- Default: `15`
452
453**Options**
454
455A font size from `6` to `100` pixels (inclusive)
456
457## Buffer Font Weight
458
459- Description: The default font weight for text in the editor.
460- Setting: `buffer_font_weight`
461- Default: `400`
462
463**Options**
464
465`integer` values between `100` and `900`
466
467## Buffer Line Height
468
469- Description: The default line height for text in the editor.
470- Setting: `buffer_line_height`
471- Default: `"comfortable"`
472
473**Options**
474
475`"standard"`, `"comfortable"` or `{ "custom": float }` (`1` is compact, `2` is loose)
476
477## Centered Layout
478
479- Description: Configuration for the centered layout mode.
480- Setting: `centered_layout`
481- Default:
482
483```json [settings]
484"centered_layout": {
485 "left_padding": 0.2,
486 "right_padding": 0.2,
487}
488```
489
490**Options**
491
492The `left_padding` and `right_padding` options define the relative width of the
493left 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`.
494
495## Close on File Delete
496
497- Description: Whether to automatically close editor tabs when their corresponding files are deleted from disk.
498- Setting: `close_on_file_delete`
499- Default: `false`
500
501**Options**
502
503`boolean` values
504
505When 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.
506
507Note: Dirty files (files with unsaved changes) will not be automatically closed even when this setting is enabled, ensuring you don't lose unsaved work.
508
509## Confirm Quit
510
511- Description: Whether or not to prompt the user to confirm before closing the application.
512- Setting: `confirm_quit`
513- Default: `false`
514
515**Options**
516
517`boolean` values
518
519## Diagnostics Max Severity
520
521- Description: Which level to use to filter out diagnostics displayed in the editor
522- Setting: `diagnostics_max_severity`
523- Default: `null`
524
525**Options**
526
5271. Allow all diagnostics (default):
528
529```json [settings]
530{
531 "diagnostics_max_severity": "all"
532}
533```
534
5352. Show only errors:
536
537```json [settings]
538{
539 "diagnostics_max_severity": "error"
540}
541```
542
5433. Show errors and warnings:
544
545```json [settings]
546{
547 "diagnostics_max_severity": "warning"
548}
549```
550
5514. Show errors, warnings, and information:
552
553```json [settings]
554{
555 "diagnostics_max_severity": "info"
556}
557```
558
5595. Show all including hints:
560
561```json [settings]
562{
563 "diagnostics_max_severity": "hint"
564}
565```
566
567## Disable AI
568
569- Description: Whether to disable all AI features in Zed
570- Setting: `disable_ai`
571- Default: `false`
572
573**Options**
574
575`boolean` values
576
577## Direnv Integration
578
579- Description: Settings for [direnv](https://direnv.net/) integration. Requires `direnv` to be installed.
580 `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.
581 It also allows for those environment variables to be used in tasks.
582- Setting: `load_direnv`
583- Default: `"direct"`
584
585**Options**
586
587There are two options to choose from:
588
5891. `shell_hook`: Use the shell hook to load direnv. This relies on direnv to activate upon entering the directory. Supports POSIX shells and fish.
5902. `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.
591
592## Double Click In Multibuffer
593
594- Description: What to do when multibuffer is double clicked in some of its excerpts (parts of singleton buffers)
595- Setting: `double_click_in_multibuffer`
596- Default: `"select"`
597
598**Options**
599
6001. Behave as a regular buffer and select the whole word (default):
601
602```json [settings]
603{
604 "double_click_in_multibuffer": "select"
605}
606```
607
6082. Open the excerpt clicked as a new buffer in the new tab:
609
610```json [settings]
611{
612 "double_click_in_multibuffer": "open"
613}
614```
615
616For the case of "open", regular selection behavior can be achieved by holding `alt` when double clicking.
617
618## Drop Target Size
619
620- Description: Relative size of the drop target in the editor that will open dropped file as a split pane (0-0.5). For example, 0.25 means if you drop onto the top/bottom quarter of the pane a new vertical split will be used, if you drop onto the left/right quarter of the pane a new horizontal split will be used.
621- Setting: `drop_target_size`
622- Default: `0.2`
623
624**Options**
625
626`float` values between `0` and `0.5`
627
628## Edit Predictions
629
630- Description: Settings for edit predictions.
631- Setting: `edit_predictions`
632- Default:
633
634```json [settings]
635 "edit_predictions": {
636 "disabled_globs": [
637 "**/.env*",
638 "**/*.pem",
639 "**/*.key",
640 "**/*.cert",
641 "**/*.crt",
642 "**/.dev.vars",
643 "**/secrets.yml"
644 ]
645 }
646```
647
648**Options**
649
650### Disabled Globs
651
652- 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.
653- Setting: `disabled_globs`
654- Default: `["**/.env*", "**/*.pem", "**/*.key", "**/*.cert", "**/*.crt", "**/.dev.vars", "**/secrets.yml"]`
655
656**Options**
657
658List of `string` values.
659
660## Edit Predictions Disabled in
661
662- Description: A list of language scopes in which edit predictions should be disabled.
663- Setting: `edit_predictions_disabled_in`
664- Default: `[]`
665
666**Options**
667
668List of `string` values
669
6701. Don't show edit predictions in comments:
671
672```json [settings]
673"disabled_in": ["comment"]
674```
675
6762. Don't show edit predictions in strings and comments:
677
678```json [settings]
679"disabled_in": ["comment", "string"]
680```
681
6823. Only in Go, don't show edit predictions in strings and comments:
683
684```json [settings]
685{
686 "languages": {
687 "Go": {
688 "edit_predictions_disabled_in": ["comment", "string"]
689 }
690 }
691}
692```
693
694## Current Line Highlight
695
696- Description: How to highlight the current line in the editor.
697- Setting: `current_line_highlight`
698- Default: `all`
699
700**Options**
701
7021. Don't highlight the current line:
703
704```json [settings]
705"current_line_highlight": "none"
706```
707
7082. Highlight the gutter area:
709
710```json [settings]
711"current_line_highlight": "gutter"
712```
713
7143. Highlight the editor area:
715
716```json [settings]
717"current_line_highlight": "line"
718```
719
7204. Highlight the full line:
721
722```json [settings]
723"current_line_highlight": "all"
724```
725
726## Selection Highlight
727
728- Description: Whether to highlight all occurrences of the selected text in an editor.
729- Setting: `selection_highlight`
730- Default: `true`
731
732## Rounded Selection
733
734- Description: Whether the text selection should have rounded corners.
735- Setting: `rounded_selection`
736- Default: `true`
737
738## Cursor Blink
739
740- Description: Whether or not the cursor blinks.
741- Setting: `cursor_blink`
742- Default: `true`
743
744**Options**
745
746`boolean` values
747
748## Cursor Shape
749
750- Description: Cursor shape for the default editor.
751- Setting: `cursor_shape`
752- Default: `bar`
753
754**Options**
755
7561. A vertical bar:
757
758```json [settings]
759"cursor_shape": "bar"
760```
761
7622. A block that surrounds the following character:
763
764```json [settings]
765"cursor_shape": "block"
766```
767
7683. An underline / underscore that runs along the following character:
769
770```json [settings]
771"cursor_shape": "underline"
772```
773
7744. An box drawn around the following character:
775
776```json [settings]
777"cursor_shape": "hollow"
778```
779
780## Gutter
781
782- Description: Settings for the editor gutter
783- Setting: `gutter`
784- Default:
785
786```json [settings]
787{
788 "gutter": {
789 "line_numbers": true,
790 "runnables": true,
791 "breakpoints": true,
792 "folds": true,
793 "min_line_number_digits": 4
794 }
795}
796```
797
798**Options**
799
800- `line_numbers`: Whether to show line numbers in the gutter
801- `runnables`: Whether to show runnable buttons in the gutter
802- `breakpoints`: Whether to show breakpoints in the gutter
803- `folds`: Whether to show fold buttons in the gutter
804- `min_line_number_digits`: Minimum number of characters to reserve space for in the gutter
805
806## Hide Mouse
807
808- Description: Determines when the mouse cursor should be hidden in an editor or input box.
809- Setting: `hide_mouse`
810- Default: `on_typing_and_movement`
811
812**Options**
813
8141. Never hide the mouse cursor:
815
816```json [settings]
817"hide_mouse": "never"
818```
819
8202. Hide only when typing:
821
822```json [settings]
823"hide_mouse": "on_typing"
824```
825
8263. Hide on both typing and cursor movement:
827
828```json [settings]
829"hide_mouse": "on_typing_and_movement"
830```
831
832## Snippet Sort Order
833
834- Description: Determines how snippets are sorted relative to other completion items.
835- Setting: `snippet_sort_order`
836- Default: `inline`
837
838**Options**
839
8401. Place snippets at the top of the completion list:
841
842```json [settings]
843"snippet_sort_order": "top"
844```
845
8462. Place snippets normally without any preference:
847
848```json [settings]
849"snippet_sort_order": "inline"
850```
851
8523. Place snippets at the bottom of the completion list:
853
854```json [settings]
855"snippet_sort_order": "bottom"
856```
857
8584. Do not show snippets in the completion list at all:
859
860```json [settings]
861"snippet_sort_order": "none"
862```
863
864## Editor Scrollbar
865
866- Description: Whether or not to show the editor scrollbar and various elements in it.
867- Setting: `scrollbar`
868- Default:
869
870```json [settings]
871"scrollbar": {
872 "show": "auto",
873 "cursors": true,
874 "git_diff": true,
875 "search_results": true,
876 "selected_text": true,
877 "selected_symbol": true,
878 "diagnostics": "all",
879 "axes": {
880 "horizontal": true,
881 "vertical": true,
882 },
883},
884```
885
886### Show Mode
887
888- Description: When to show the editor scrollbar.
889- Setting: `show`
890- Default: `auto`
891
892**Options**
893
8941. Show the scrollbar if there's important information or follow the system's configured behavior:
895
896```json [settings]
897"scrollbar": {
898 "show": "auto"
899}
900```
901
9022. Match the system's configured behavior:
903
904```json [settings]
905"scrollbar": {
906 "show": "system"
907}
908```
909
9103. Always show the scrollbar:
911
912```json [settings]
913"scrollbar": {
914 "show": "always"
915}
916```
917
9184. Never show the scrollbar:
919
920```json [settings]
921"scrollbar": {
922 "show": "never"
923}
924```
925
926### Cursor Indicators
927
928- Description: Whether to show cursor positions in the scrollbar.
929- Setting: `cursors`
930- Default: `true`
931
932**Options**
933
934`boolean` values
935
936### Git Diff Indicators
937
938- Description: Whether to show git diff indicators in the scrollbar.
939- Setting: `git_diff`
940- Default: `true`
941
942**Options**
943
944`boolean` values
945
946### Search Results Indicators
947
948- Description: Whether to show buffer search results in the scrollbar.
949- Setting: `search_results`
950- Default: `true`
951
952**Options**
953
954`boolean` values
955
956### Selected Text Indicators
957
958- Description: Whether to show selected text occurrences in the scrollbar.
959- Setting: `selected_text`
960- Default: `true`
961
962**Options**
963
964`boolean` values
965
966### Selected Symbols Indicators
967
968- Description: Whether to show selected symbol occurrences in the scrollbar.
969- Setting: `selected_symbol`
970- Default: `true`
971
972**Options**
973
974`boolean` values
975
976### Diagnostics
977
978- Description: Which diagnostic indicators to show in the scrollbar.
979- Setting: `diagnostics`
980- Default: `all`
981
982**Options**
983
9841. Show all diagnostics:
985
986```json [settings]
987{
988 "show_diagnostics": "all"
989}
990```
991
9922. Do not show any diagnostics:
993
994```json [settings]
995{
996 "show_diagnostics": "off"
997}
998```
999
10003. Show only errors:
1001
1002```json [settings]
1003{
1004 "show_diagnostics": "error"
1005}
1006```
1007
10084. Show only errors and warnings:
1009
1010```json [settings]
1011{
1012 "show_diagnostics": "warning"
1013}
1014```
1015
10165. Show only errors, warnings, and information:
1017
1018```json [settings]
1019{
1020 "show_diagnostics": "info"
1021}
1022```
1023
1024### Axes
1025
1026- Description: Forcefully enable or disable the scrollbar for each axis
1027- Setting: `axes`
1028- Default:
1029
1030```json [settings]
1031"scrollbar": {
1032 "axes": {
1033 "horizontal": true,
1034 "vertical": true,
1035 },
1036}
1037```
1038
1039#### Horizontal
1040
1041- Description: When false, forcefully disables the horizontal scrollbar. Otherwise, obey other settings.
1042- Setting: `horizontal`
1043- Default: `true`
1044
1045**Options**
1046
1047`boolean` values
1048
1049#### Vertical
1050
1051- Description: When false, forcefully disables the vertical scrollbar. Otherwise, obey other settings.
1052- Setting: `vertical`
1053- Default: `true`
1054
1055**Options**
1056
1057`boolean` values
1058
1059## Minimap
1060
1061- Description: Settings related to the editor's minimap, which provides an overview of your document.
1062- Setting: `minimap`
1063- Default:
1064
1065```json [settings]
1066{
1067 "minimap": {
1068 "show": "never",
1069 "thumb": "always",
1070 "thumb_border": "left_open",
1071 "current_line_highlight": null
1072 }
1073}
1074```
1075
1076### Show Mode
1077
1078- Description: When to show the minimap in the editor.
1079- Setting: `show`
1080- Default: `never`
1081
1082**Options**
1083
10841. Always show the minimap:
1085
1086```json [settings]
1087{
1088 "show": "always"
1089}
1090```
1091
10922. Show the minimap if the editor's scrollbars are visible:
1093
1094```json [settings]
1095{
1096 "show": "auto"
1097}
1098```
1099
11003. Never show the minimap:
1101
1102```json [settings]
1103{
1104 "show": "never"
1105}
1106```
1107
1108### Thumb Display
1109
1110- Description: When to show the minimap thumb (the visible editor area) in the minimap.
1111- Setting: `thumb`
1112- Default: `always`
1113
1114**Options**
1115
11161. Show the minimap thumb when hovering over the minimap:
1117
1118```json [settings]
1119{
1120 "thumb": "hover"
1121}
1122```
1123
11242. Always show the minimap thumb:
1125
1126```json [settings]
1127{
1128 "thumb": "always"
1129}
1130```
1131
1132### Thumb Border
1133
1134- Description: How the minimap thumb border should look.
1135- Setting: `thumb_border`
1136- Default: `left_open`
1137
1138**Options**
1139
11401. Display a border on all sides of the thumb:
1141
1142```json [settings]
1143{
1144 "thumb_border": "full"
1145}
1146```
1147
11482. Display a border on all sides except the left side:
1149
1150```json [settings]
1151{
1152 "thumb_border": "left_open"
1153}
1154```
1155
11563. Display a border on all sides except the right side:
1157
1158```json [settings]
1159{
1160 "thumb_border": "right_open"
1161}
1162```
1163
11644. Display a border only on the left side:
1165
1166```json [settings]
1167{
1168 "thumb_border": "left_only"
1169}
1170```
1171
11725. Display the thumb without any border:
1173
1174```json [settings]
1175{
1176 "thumb_border": "none"
1177}
1178```
1179
1180### Current Line Highlight
1181
1182- Description: How to highlight the current line in the minimap.
1183- Setting: `current_line_highlight`
1184- Default: `null`
1185
1186**Options**
1187
11881. Inherit the editor's current line highlight setting:
1189
1190```json [settings]
1191{
1192 "minimap": {
1193 "current_line_highlight": null
1194 }
1195}
1196```
1197
11982. Highlight the current line in the minimap:
1199
1200```json [settings]
1201{
1202 "minimap": {
1203 "current_line_highlight": "line"
1204 }
1205}
1206```
1207
1208or
1209
1210```json [settings]
1211{
1212 "minimap": {
1213 "current_line_highlight": "all"
1214 }
1215}
1216```
1217
12183. Do not highlight the current line in the minimap:
1219
1220```json [settings]
1221{
1222 "minimap": {
1223 "current_line_highlight": "gutter"
1224 }
1225}
1226```
1227
1228or
1229
1230```json [settings]
1231{
1232 "minimap": {
1233 "current_line_highlight": "none"
1234 }
1235}
1236```
1237
1238## Editor Tab Bar
1239
1240- Description: Settings related to the editor's tab bar.
1241- Settings: `tab_bar`
1242- Default:
1243
1244```json [settings]
1245"tab_bar": {
1246 "show": true,
1247 "show_nav_history_buttons": true,
1248 "show_tab_bar_buttons": true
1249}
1250```
1251
1252### Show
1253
1254- Description: Whether or not to show the tab bar in the editor.
1255- Setting: `show`
1256- Default: `true`
1257
1258**Options**
1259
1260`boolean` values
1261
1262### Navigation History Buttons
1263
1264- Description: Whether or not to show the navigation history buttons.
1265- Setting: `show_nav_history_buttons`
1266- Default: `true`
1267
1268**Options**
1269
1270`boolean` values
1271
1272### Tab Bar Buttons
1273
1274- Description: Whether or not to show the tab bar buttons.
1275- Setting: `show_tab_bar_buttons`
1276- Default: `true`
1277
1278**Options**
1279
1280`boolean` values
1281
1282## Editor Tabs
1283
1284- Description: Configuration for the editor tabs.
1285- Setting: `tabs`
1286- Default:
1287
1288```json [settings]
1289"tabs": {
1290 "close_position": "right",
1291 "file_icons": false,
1292 "git_status": false,
1293 "activate_on_close": "history",
1294 "show_close_button": "hover",
1295 "show_diagnostics": "off"
1296},
1297```
1298
1299### Close Position
1300
1301- Description: Where to display close button within a tab.
1302- Setting: `close_position`
1303- Default: `right`
1304
1305**Options**
1306
13071. Display the close button on the right:
1308
1309```json [settings]
1310{
1311 "close_position": "right"
1312}
1313```
1314
13152. Display the close button on the left:
1316
1317```json [settings]
1318{
1319 "close_position": "left"
1320}
1321```
1322
1323### File Icons
1324
1325- Description: Whether to show the file icon for a tab.
1326- Setting: `file_icons`
1327- Default: `false`
1328
1329### Git Status
1330
1331- Description: Whether or not to show Git file status in tab.
1332- Setting: `git_status`
1333- Default: `false`
1334
1335### Activate on close
1336
1337- Description: What to do after closing the current tab.
1338- Setting: `activate_on_close`
1339- Default: `history`
1340
1341**Options**
1342
13431. Activate the tab that was open previously:
1344
1345```json [settings]
1346{
1347 "activate_on_close": "history"
1348}
1349```
1350
13512. Activate the right neighbour tab if present:
1352
1353```json [settings]
1354{
1355 "activate_on_close": "neighbour"
1356}
1357```
1358
13593. Activate the left neighbour tab if present:
1360
1361```json [settings]
1362{
1363 "activate_on_close": "left_neighbour"
1364}
1365```
1366
1367### Show close button
1368
1369- Description: Controls the appearance behavior of the tab's close button.
1370- Setting: `show_close_button`
1371- Default: `hover`
1372
1373**Options**
1374
13751. Show it just upon hovering the tab:
1376
1377```json [settings]
1378{
1379 "show_close_button": "hover"
1380}
1381```
1382
13832. Show it persistently:
1384
1385```json [settings]
1386{
1387 "show_close_button": "always"
1388}
1389```
1390
13913. Never show it, even if hovering it:
1392
1393```json [settings]
1394{
1395 "show_close_button": "hidden"
1396}
1397```
1398
1399### Show Diagnostics
1400
1401- 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.
1402- Setting: `show_diagnostics`
1403- Default: `off`
1404
1405**Options**
1406
14071. Do not mark any files:
1408
1409```json [settings]
1410{
1411 "show_diagnostics": "off"
1412}
1413```
1414
14152. Only mark files with errors:
1416
1417```json [settings]
1418{
1419 "show_diagnostics": "errors"
1420}
1421```
1422
14233. Mark files with errors and warnings:
1424
1425```json [settings]
1426{
1427 "show_diagnostics": "all"
1428}
1429```
1430
1431### Show Inline Code Actions
1432
1433- Description: Whether to show code action button at start of buffer line.
1434- Setting: `inline_code_actions`
1435- Default: `true`
1436
1437**Options**
1438
1439`boolean` values
1440
1441### Drag And Drop Selection
1442
1443- 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.
1444- Setting: `drag_and_drop_selection`
1445- Default:
1446
1447```json [settings]
1448"drag_and_drop_selection": {
1449 "enabled": true,
1450 "delay": 300
1451}
1452```
1453
1454## Editor Toolbar
1455
1456- Description: Whether or not to show various elements in the editor toolbar.
1457- Setting: `toolbar`
1458- Default:
1459
1460```json [settings]
1461"toolbar": {
1462 "breadcrumbs": true,
1463 "quick_actions": true,
1464 "selections_menu": true,
1465 "agent_review": true,
1466 "code_actions": false
1467},
1468```
1469
1470**Options**
1471
1472Each option controls displaying of a particular toolbar element. If all elements are hidden, the editor toolbar is not displayed.
1473
1474## Use System Tabs
1475
1476- Description: Whether to allow windows to tab together based on the user’s tabbing preference (macOS only).
1477- Setting: `use_system_window_tabs`
1478- Default: `false`
1479
1480**Options**
1481
1482This setting enables integration with macOS’s native window tabbing feature. When set to `true`, Zed windows can be grouped together as tabs in a single macOS window, following the system-wide tabbing preferences set by the user (such as "Always", "In Full Screen", or "Never"). This setting is only available on macOS.
1483
1484## Enable Language Server
1485
1486- Description: Whether or not to use language servers to provide code intelligence.
1487- Setting: `enable_language_server`
1488- Default: `true`
1489
1490**Options**
1491
1492`boolean` values
1493
1494## Ensure Final Newline On Save
1495
1496- Description: Removes any lines containing only whitespace at the end of the file and ensures just one newline at the end.
1497- Setting: `ensure_final_newline_on_save`
1498- Default: `true`
1499
1500**Options**
1501
1502`boolean` values
1503
1504## Expand Excerpt Lines
1505
1506- Description: The default number of lines to expand excerpts in the multibuffer by
1507- Setting: `expand_excerpt_lines`
1508- Default: `5`
1509
1510**Options**
1511
1512Positive `integer` values
1513
1514## Excerpt Context Lines
1515
1516- Description: The number of lines of context to provide when showing excerpts in the multibuffer.
1517- Setting: `excerpt_context_lines`
1518- Default: `2`
1519
1520**Options**
1521
1522Positive `integer` value between 1 and 32. Values outside of this range will be clamped to this range.
1523
1524## Extend Comment On Newline
1525
1526- Description: Whether to start a new line with a comment when a previous line is a comment as well.
1527- Setting: `extend_comment_on_newline`
1528- Default: `true`
1529
1530**Options**
1531
1532`boolean` values
1533
1534## Status Bar
1535
1536- Description: Control various elements in the status bar. Note that some items in the status bar have their own settings set elsewhere.
1537- Setting: `status_bar`
1538- Default:
1539
1540```json [settings]
1541"status_bar": {
1542 "active_language_button": true,
1543 "cursor_position_button": true,
1544 "line_endings_button": false,
1545 "encoding_indicator": true,
1546},
1547```
1548
1549There is an experimental setting that completely hides the status bar. This causes major usability problems (you will be unable to use many of Zed's features), but is provided for those who value screen real-estate above all else.
1550
1551```json
1552"status_bar": {
1553 "experimental.show": false
1554}
1555```
1556
1557## LSP
1558
1559- Description: Configuration for language servers.
1560- Setting: `lsp`
1561- Default: `null`
1562
1563**Options**
1564
1565The following settings can be overridden for specific language servers:
1566
1567- `initialization_options`
1568- `settings`
1569
1570To override configuration for a language server, add an entry for that language server's name to the `lsp` value.
1571
1572Some 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.
1573
1574For example to pass the `check` option to `rust-analyzer`, use the following configuration:
1575
1576```json [settings]
1577"lsp": {
1578 "rust-analyzer": {
1579 "initialization_options": {
1580 "check": {
1581 "command": "clippy" // rust-analyzer.check.command (default: "check")
1582 }
1583 }
1584 }
1585}
1586```
1587
1588While other options may be changed at a runtime and should be placed under `settings`:
1589
1590```json [settings]
1591"lsp": {
1592 "yaml-language-server": {
1593 "settings": {
1594 "yaml": {
1595 "keyOrdering": true // Enforces alphabetical ordering of keys in maps
1596 }
1597 }
1598 }
1599}
1600```
1601
1602## Global LSP Settings
1603
1604- Description: Configuration for global LSP settings that apply to all language servers
1605- Setting: `global_lsp_settings`
1606- Default:
1607
1608```json [settings]
1609{
1610 "global_lsp_settings": {
1611 "button": true
1612 }
1613}
1614```
1615
1616**Options**
1617
1618- `button`: Whether to show the LSP status button in the status bar
1619
1620## LSP Highlight Debounce
1621
1622- Description: The debounce delay in milliseconds before querying highlights from the language server based on the current cursor location.
1623- Setting: `lsp_highlight_debounce`
1624- Default: `75`
1625
1626**Options**
1627
1628`integer` values representing milliseconds
1629
1630## Features
1631
1632- Description: Features that can be globally enabled or disabled
1633- Setting: `features`
1634- Default:
1635
1636```json [settings]
1637{
1638 "features": {
1639 "edit_prediction_provider": "zed"
1640 }
1641}
1642```
1643
1644### Edit Prediction Provider
1645
1646- Description: Which edit prediction provider to use
1647- Setting: `edit_prediction_provider`
1648- Default: `"zed"`
1649
1650**Options**
1651
16521. Use Zeta as the edit prediction provider:
1653
1654```json [settings]
1655{
1656 "features": {
1657 "edit_prediction_provider": "zed"
1658 }
1659}
1660```
1661
16622. Use Copilot as the edit prediction provider:
1663
1664```json [settings]
1665{
1666 "features": {
1667 "edit_prediction_provider": "copilot"
1668 }
1669}
1670```
1671
16723. Use Supermaven as the edit prediction provider:
1673
1674```json [settings]
1675{
1676 "features": {
1677 "edit_prediction_provider": "supermaven"
1678 }
1679}
1680```
1681
16824. Turn off edit predictions across all providers
1683
1684```json [settings]
1685{
1686 "features": {
1687 "edit_prediction_provider": "none"
1688 }
1689}
1690```
1691
1692## Format On Save
1693
1694- Description: Whether or not to perform a buffer format before saving.
1695- Setting: `format_on_save`
1696- Default: `on`
1697
1698**Options**
1699
17001. `on`, enables format on save obeying `formatter` setting:
1701
1702```json [settings]
1703{
1704 "format_on_save": "on"
1705}
1706```
1707
17082. `off`, disables format on save:
1709
1710```json [settings]
1711{
1712 "format_on_save": "off"
1713}
1714```
1715
1716## Formatter
1717
1718- Description: How to perform a buffer format.
1719- Setting: `formatter`
1720- Default: `auto`
1721
1722**Options**
1723
17241. To use the current language server, use `"language_server"`:
1725
1726```json [settings]
1727{
1728 "formatter": "language_server"
1729}
1730```
1731
17322. 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):
1733
1734```json [settings]
1735{
1736 "formatter": {
1737 "external": {
1738 "command": "sed",
1739 "arguments": ["-e", "s/ *$//"]
1740 }
1741 }
1742}
1743```
1744
17453. 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.
1746
1747WARNING: `{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.
1748
1749```json [settings]
1750 "formatter": {
1751 "external": {
1752 "command": "prettier",
1753 "arguments": ["--stdin-filepath", "{buffer_path}"]
1754 }
1755 }
1756```
1757
17584. Or to use code actions provided by the connected language servers, use `"code_actions"`:
1759
1760```json [settings]
1761{
1762 "formatter": [
1763 // Use ESLint's --fix:
1764 { "code_action": "source.fixAll.eslint" },
1765 // Organize imports on save:
1766 { "code_action": "source.organizeImports" }
1767 ]
1768}
1769```
1770
17715. Or to use multiple formatters consecutively, use an array of formatters:
1772
1773```json [settings]
1774{
1775 "formatter": [
1776 { "language_server": { "name": "rust-analyzer" } },
1777 {
1778 "external": {
1779 "command": "sed",
1780 "arguments": ["-e", "s/ *$//"]
1781 }
1782 }
1783 ]
1784}
1785```
1786
1787Here `rust-analyzer` will be used first to format the code, followed by a call of sed.
1788If any of the formatters fails, the subsequent ones will still be executed.
1789
1790## Auto close
1791
1792- Description: Whether to automatically add matching closing characters when typing opening parenthesis, bracket, brace, single or double quote characters.
1793- Setting: `use_autoclose`
1794- Default: `true`
1795
1796**Options**
1797
1798`boolean` values
1799
1800## Always Treat Brackets As Autoclosed
1801
1802- Description: Controls how the editor handles the autoclosed characters.
1803- Setting: `always_treat_brackets_as_autoclosed`
1804- Default: `false`
1805
1806**Options**
1807
1808`boolean` values
1809
1810**Example**
1811
1812If the setting is set to `true`:
1813
18141. Enter in the editor: `)))`
18152. Move the cursor to the start: `^)))`
18163. Enter again: `)))`
1817
1818The result is still `)))` and not `))))))`, which is what it would be by default.
1819
1820## File Scan Exclusions
1821
1822- Setting: `file_scan_exclusions`
1823- 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`.
1824- Default:
1825
1826```json [settings]
1827"file_scan_exclusions": [
1828 "**/.git",
1829 "**/.svn",
1830 "**/.hg",
1831 "**/.jj",
1832 "**/CVS",
1833 "**/.DS_Store",
1834 "**/Thumbs.db",
1835 "**/.classpath",
1836 "**/.settings"
1837],
1838```
1839
1840Note, 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.
1841
1842## File Scan Inclusions
1843
1844- Setting: `file_scan_inclusions`
1845- 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.
1846- Default:
1847
1848```json [settings]
1849"file_scan_inclusions": [".env*"],
1850```
1851
1852## File Types
1853
1854- Setting: `file_types`
1855- Description: Configure how Zed selects a language for a file based on its filename or extension. Supports glob entries.
1856- Default:
1857
1858```json [settings]
1859"file_types": {
1860 "JSONC": ["**/.zed/**/*.json", "**/zed/**/*.json", "**/Zed/**/*.json", "**/.vscode/**/*.json"],
1861 "Shell Script": [".env.*"]
1862}
1863```
1864
1865**Examples**
1866
1867To interpret all `.c` files as C++, files called `MyLockFile` as TOML and files starting with `Dockerfile` as Dockerfile:
1868
1869```json [settings]
1870{
1871 "file_types": {
1872 "C++": ["c"],
1873 "TOML": ["MyLockFile"],
1874 "Dockerfile": ["Dockerfile*"]
1875 }
1876}
1877```
1878
1879## Diagnostics
1880
1881- Description: Configuration for diagnostics-related features.
1882- Setting: `diagnostics`
1883- Default:
1884
1885```json [settings]
1886{
1887 "diagnostics": {
1888 "include_warnings": true,
1889 "inline": {
1890 "enabled": false
1891 },
1892 "update_with_cursor": false,
1893 "primary_only": false,
1894 "use_rendered": false
1895 }
1896}
1897```
1898
1899### Inline Diagnostics
1900
1901- Description: Whether or not to show diagnostics information inline.
1902- Setting: `inline`
1903- Default:
1904
1905```json [settings]
1906{
1907 "diagnostics": {
1908 "inline": {
1909 "enabled": false,
1910 "update_debounce_ms": 150,
1911 "padding": 4,
1912 "min_column": 0,
1913 "max_severity": null
1914 }
1915 }
1916}
1917```
1918
1919**Options**
1920
19211. Enable inline diagnostics.
1922
1923```json [settings]
1924{
1925 "diagnostics": {
1926 "inline": {
1927 "enabled": true
1928 }
1929 }
1930}
1931```
1932
19332. Delay diagnostic updates until some time after the last diagnostic update.
1934
1935```json [settings]
1936{
1937 "diagnostics": {
1938 "inline": {
1939 "enabled": true,
1940 "update_debounce_ms": 150
1941 }
1942 }
1943}
1944```
1945
19463. Set padding between the end of the source line and the start of the diagnostic.
1947
1948```json [settings]
1949{
1950 "diagnostics": {
1951 "inline": {
1952 "enabled": true,
1953 "padding": 4
1954 }
1955 }
1956}
1957```
1958
19594. Horizontally align inline diagnostics at the given column.
1960
1961```json [settings]
1962{
1963 "diagnostics": {
1964 "inline": {
1965 "enabled": true,
1966 "min_column": 80
1967 }
1968 }
1969}
1970```
1971
19725. Show only warning and error diagnostics.
1973
1974```json [settings]
1975{
1976 "diagnostics": {
1977 "inline": {
1978 "enabled": true,
1979 "max_severity": "warning"
1980 }
1981 }
1982}
1983```
1984
1985## Git
1986
1987- Description: Configuration for git-related features.
1988- Setting: `git`
1989- Default:
1990
1991```json [settings]
1992{
1993 "git": {
1994 "git_gutter": "tracked_files",
1995 "inline_blame": {
1996 "enabled": true
1997 },
1998 "branch_picker": {
1999 "show_author_name": true
2000 },
2001 "hunk_style": "staged_hollow"
2002 }
2003}
2004```
2005
2006### Git Gutter
2007
2008- Description: Whether or not to show the git gutter.
2009- Setting: `git_gutter`
2010- Default: `tracked_files`
2011
2012**Options**
2013
20141. Show git gutter in tracked files
2015
2016```json [settings]
2017{
2018 "git": {
2019 "git_gutter": "tracked_files"
2020 }
2021}
2022```
2023
20242. Hide git gutter
2025
2026```json [settings]
2027{
2028 "git": {
2029 "git_gutter": "hide"
2030 }
2031}
2032```
2033
2034### Gutter Debounce
2035
2036- Description: Sets the debounce threshold (in milliseconds) after which changes are reflected in the git gutter.
2037- Setting: `gutter_debounce`
2038- Default: `null`
2039
2040**Options**
2041
2042`integer` values representing milliseconds
2043
2044Example:
2045
2046```json [settings]
2047{
2048 "git": {
2049 "gutter_debounce": 100
2050 }
2051}
2052```
2053
2054### Inline Git Blame
2055
2056- Description: Whether or not to show git blame information inline, on the currently focused line.
2057- Setting: `inline_blame`
2058- Default:
2059
2060```json [settings]
2061{
2062 "git": {
2063 "inline_blame": {
2064 "enabled": true
2065 }
2066 }
2067}
2068```
2069
2070**Options**
2071
20721. Disable inline git blame:
2073
2074```json [settings]
2075{
2076 "git": {
2077 "inline_blame": {
2078 "enabled": false
2079 }
2080 }
2081}
2082```
2083
20842. Only show inline git blame after a delay (that starts after cursor stops moving):
2085
2086```json [settings]
2087{
2088 "git": {
2089 "inline_blame": {
2090 "delay_ms": 500
2091 }
2092 }
2093}
2094```
2095
20963. Show a commit summary next to the commit date and author:
2097
2098```json [settings]
2099{
2100 "git": {
2101 "inline_blame": {
2102 "show_commit_summary": true
2103 }
2104 }
2105}
2106```
2107
21084. Use this as the minimum column at which to display inline blame information:
2109
2110```json [settings]
2111{
2112 "git": {
2113 "inline_blame": {
2114 "min_column": 80
2115 }
2116 }
2117}
2118```
2119
21205. Set the padding between the end of the line and the inline blame hint, in ems:
2121
2122```json [settings]
2123{
2124 "git": {
2125 "inline_blame": {
2126 "padding": 10
2127 }
2128 }
2129}
2130```
2131
2132### Branch Picker
2133
2134- Description: Configuration related to the branch picker.
2135- Setting: `branch_picker`
2136- Default:
2137
2138```json [settings]
2139{
2140 "git": {
2141 "branch_picker": {
2142 "show_author_name": false
2143 }
2144 }
2145}
2146```
2147
2148**Options**
2149
21501. Show the author name in the branch picker:
2151
2152```json [settings]
2153{
2154 "git": {
2155 "branch_picker": {
2156 "show_author_name": true
2157 }
2158 }
2159}
2160```
2161
2162### Hunk Style
2163
2164- Description: What styling we should use for the diff hunks.
2165- Setting: `hunk_style`
2166- Default:
2167
2168```json [settings]
2169{
2170 "git": {
2171 "hunk_style": "staged_hollow"
2172 }
2173}
2174```
2175
2176**Options**
2177
21781. Show the staged hunks faded out and with a border:
2179
2180```json [settings]
2181{
2182 "git": {
2183 "hunk_style": "staged_hollow"
2184 }
2185}
2186```
2187
21882. Show unstaged hunks faded out and with a border:
2189
2190```json [settings]
2191{
2192 "git": {
2193 "hunk_style": "unstaged_hollow"
2194 }
2195}
2196```
2197
2198## Go to Definition Fallback
2199
2200- Description: What to do when the {#action editor::GoToDefinition} action fails to find a definition
2201- Setting: `go_to_definition_fallback`
2202- Default: `"find_all_references"`
2203
2204**Options**
2205
22061. Do nothing:
2207
2208```json [settings]
2209{
2210 "go_to_definition_fallback": "none"
2211}
2212```
2213
22142. Find references for the same symbol (default):
2215
2216```json [settings]
2217{
2218 "go_to_definition_fallback": "find_all_references"
2219}
2220```
2221
2222## Hard Tabs
2223
2224- Description: Whether to indent lines using tab characters or multiple spaces.
2225- Setting: `hard_tabs`
2226- Default: `false`
2227
2228**Options**
2229
2230`boolean` values
2231
2232## Helix Mode
2233
2234- Description: Whether or not to enable Helix mode. Enabling `helix_mode` also enables `vim_mode`. See the [Helix documentation](./helix.md) for more details.
2235- Setting: `helix_mode`
2236- Default: `false`
2237
2238**Options**
2239
2240`boolean` values
2241
2242## Indent Guides
2243
2244- Description: Configuration related to indent guides. Indent guides can be configured separately for each language.
2245- Setting: `indent_guides`
2246- Default:
2247
2248```json [settings]
2249{
2250 "indent_guides": {
2251 "enabled": true,
2252 "line_width": 1,
2253 "active_line_width": 1,
2254 "coloring": "fixed",
2255 "background_coloring": "disabled"
2256 }
2257}
2258```
2259
2260**Options**
2261
22621. Disable indent guides
2263
2264```json [settings]
2265{
2266 "indent_guides": {
2267 "enabled": false
2268 }
2269}
2270```
2271
22722. Enable indent guides for a specific language.
2273
2274```json [settings]
2275{
2276 "languages": {
2277 "Python": {
2278 "indent_guides": {
2279 "enabled": true
2280 }
2281 }
2282 }
2283}
2284```
2285
22863. Enable indent aware coloring ("rainbow indentation").
2287 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.
2288
2289```json [settings]
2290{
2291 "indent_guides": {
2292 "enabled": true,
2293 "coloring": "indent_aware"
2294 }
2295}
2296```
2297
22984. Enable indent aware background coloring ("rainbow indentation").
2299 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.
2300
2301```json [settings]
2302{
2303 "indent_guides": {
2304 "enabled": true,
2305 "coloring": "indent_aware",
2306 "background_coloring": "indent_aware"
2307 }
2308}
2309```
2310
2311## Hover Popover Enabled
2312
2313- Description: Whether or not to show the informational hover box when moving the mouse over symbols in the editor.
2314- Setting: `hover_popover_enabled`
2315- Default: `true`
2316
2317**Options**
2318
2319`boolean` values
2320
2321## Hover Popover Delay
2322
2323- Description: Time to wait in milliseconds before showing the informational hover box.
2324- Setting: `hover_popover_delay`
2325- Default: `300`
2326
2327**Options**
2328
2329`integer` values representing milliseconds
2330
2331## Icon Theme
2332
2333- 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.
2334- Setting: `icon_theme`
2335- Default: `Zed (Default)`
2336
2337### Icon Theme Object
2338
2339- Description: Specify the icon theme using an object that includes the `mode`, `dark`, and `light`.
2340- Setting: `icon_theme`
2341- Default:
2342
2343```json [settings]
2344"icon_theme": {
2345 "mode": "system",
2346 "dark": "Zed (Default)",
2347 "light": "Zed (Default)"
2348},
2349```
2350
2351### Mode
2352
2353- Description: Specify the icon theme mode.
2354- Setting: `mode`
2355- Default: `system`
2356
2357**Options**
2358
23591. Set the icon theme to dark mode
2360
2361```json [settings]
2362{
2363 "mode": "dark"
2364}
2365```
2366
23672. Set the icon theme to light mode
2368
2369```json [settings]
2370{
2371 "mode": "light"
2372}
2373```
2374
23753. Set the icon theme to system mode
2376
2377```json [settings]
2378{
2379 "mode": "system"
2380}
2381```
2382
2383### Dark
2384
2385- Description: The name of the dark icon theme.
2386- Setting: `dark`
2387- Default: `Zed (Default)`
2388
2389**Options**
2390
2391Run the {#action icon_theme_selector::Toggle} action in the command palette to see a current list of valid icon themes names.
2392
2393### Light
2394
2395- Description: The name of the light icon theme.
2396- Setting: `light`
2397- Default: `Zed (Default)`
2398
2399**Options**
2400
2401Run the {#action icon_theme_selector::Toggle} action in the command palette to see a current list of valid icon themes names.
2402
2403## Image Viewer
2404
2405- Description: Settings for image viewer functionality
2406- Setting: `image_viewer`
2407- Default:
2408
2409```json [settings]
2410{
2411 "image_viewer": {
2412 "unit": "binary"
2413 }
2414}
2415```
2416
2417**Options**
2418
2419### Unit
2420
2421- Description: The unit for image file sizes
2422- Setting: `unit`
2423- Default: `"binary"`
2424
2425**Options**
2426
24271. Use binary units (KiB, MiB):
2428
2429```json [settings]
2430{
2431 "image_viewer": {
2432 "unit": "binary"
2433 }
2434}
2435```
2436
24372. Use decimal units (KB, MB):
2438
2439```json [settings]
2440{
2441 "image_viewer": {
2442 "unit": "decimal"
2443 }
2444}
2445```
2446
2447## Inlay hints
2448
2449- Description: Configuration for displaying extra text with hints in the editor.
2450- Setting: `inlay_hints`
2451- Default:
2452
2453```json [settings]
2454"inlay_hints": {
2455 "enabled": false,
2456 "show_type_hints": true,
2457 "show_parameter_hints": true,
2458 "show_other_hints": true,
2459 "show_background": false,
2460 "edit_debounce_ms": 700,
2461 "scroll_debounce_ms": 50,
2462 "toggle_on_modifiers_press": null
2463}
2464```
2465
2466**Options**
2467
2468Inlay hints querying consists of two parts: editor (client) and LSP server.
2469With 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.
2470At 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.
2471
2472The following languages have inlay hints preconfigured by Zed:
2473
2474- [Go](https://docs.zed.dev/languages/go)
2475- [Rust](https://docs.zed.dev/languages/rust)
2476- [Svelte](https://docs.zed.dev/languages/svelte)
2477- [TypeScript](https://docs.zed.dev/languages/typescript)
2478
2479Use the `lsp` section for the server configuration. Examples are provided in the corresponding language documentation.
2480
2481Hints are not instantly queried in Zed, two kinds of debounces are used, either may be set to 0 to be disabled.
2482Settings-related hint updates are not debounced.
2483
2484All possible config values for `toggle_on_modifiers_press` are:
2485
2486```json [settings]
2487"inlay_hints": {
2488 "toggle_on_modifiers_press": {
2489 "control": true,
2490 "shift": true,
2491 "alt": true,
2492 "platform": true,
2493 "function": true
2494 }
2495}
2496```
2497
2498Unspecified values have a `false` value, hints won't be toggled if all the modifiers are `false` or not all the modifiers are pressed.
2499
2500## Journal
2501
2502- Description: Configuration for the journal.
2503- Setting: `journal`
2504- Default:
2505
2506```json [settings]
2507"journal": {
2508 "path": "~",
2509 "hour_format": "hour12"
2510}
2511```
2512
2513### Path
2514
2515- Description: The path of the directory where journal entries are stored.
2516- Setting: `path`
2517- Default: `~`
2518
2519**Options**
2520
2521`string` values
2522
2523### Hour Format
2524
2525- Description: The format to use for displaying hours in the journal.
2526- Setting: `hour_format`
2527- Default: `hour12`
2528
2529**Options**
2530
25311. 12-hour format:
2532
2533```json [settings]
2534{
2535 "hour_format": "hour12"
2536}
2537```
2538
25392. 24-hour format:
2540
2541```json [settings]
2542{
2543 "hour_format": "hour24"
2544}
2545```
2546
2547## JSX Tag Auto Close
2548
2549- Description: Whether to automatically close JSX tags
2550- Setting: `jsx_tag_auto_close`
2551- Default:
2552
2553```json [settings]
2554{
2555 "jsx_tag_auto_close": {
2556 "enabled": true
2557 }
2558}
2559```
2560
2561**Options**
2562
2563- `enabled`: Whether to enable automatic JSX tag closing
2564
2565## Languages
2566
2567- Description: Configuration for specific languages.
2568- Setting: `languages`
2569- Default: `null`
2570
2571**Options**
2572
2573To override settings for a language, add an entry for that languages name to the `languages` value. Example:
2574
2575```json [settings]
2576"languages": {
2577 "C": {
2578 "format_on_save": "off",
2579 "preferred_line_length": 64,
2580 "soft_wrap": "preferred_line_length"
2581 },
2582 "JSON": {
2583 "tab_size": 4
2584 }
2585}
2586```
2587
2588The following settings can be overridden for each specific language:
2589
2590- [`enable_language_server`](#enable-language-server)
2591- [`ensure_final_newline_on_save`](#ensure-final-newline-on-save)
2592- [`format_on_save`](#format-on-save)
2593- [`formatter`](#formatter)
2594- [`hard_tabs`](#hard-tabs)
2595- [`preferred_line_length`](#preferred-line-length)
2596- [`remove_trailing_whitespace_on_save`](#remove-trailing-whitespace-on-save)
2597- [`show_edit_predictions`](#show-edit-predictions)
2598- [`show_whitespaces`](#show-whitespaces)
2599- [`whitespace_map`](#whitespace-map)
2600- [`soft_wrap`](#soft-wrap)
2601- [`tab_size`](#tab-size)
2602- [`use_autoclose`](#use-autoclose)
2603- [`always_treat_brackets_as_autoclosed`](#always-treat-brackets-as-autoclosed)
2604
2605These values take in the same options as the root-level settings with the same name.
2606
2607## Language Models
2608
2609- Description: Configuration for language model providers
2610- Setting: `language_models`
2611- Default:
2612
2613```json [settings]
2614{
2615 "language_models": {
2616 "anthropic": {
2617 "api_url": "https://api.anthropic.com"
2618 },
2619 "google": {
2620 "api_url": "https://generativelanguage.googleapis.com"
2621 },
2622 "ollama": {
2623 "api_url": "http://localhost:11434"
2624 },
2625 "openai": {
2626 "api_url": "https://api.openai.com/v1"
2627 }
2628 }
2629}
2630```
2631
2632**Options**
2633
2634Configuration for various AI model providers including API URLs and authentication settings.
2635
2636## Line Indicator Format
2637
2638- Description: Format for line indicator in the status bar
2639- Setting: `line_indicator_format`
2640- Default: `"short"`
2641
2642**Options**
2643
26441. Short format:
2645
2646```json [settings]
2647{
2648 "line_indicator_format": "short"
2649}
2650```
2651
26522. Long format:
2653
2654```json [settings]
2655{
2656 "line_indicator_format": "long"
2657}
2658```
2659
2660## Linked Edits
2661
2662- Description: Whether to perform linked edits of associated ranges, if the language server supports it. For example, when editing opening `<html>` tag, the contents of the closing `</html>` tag will be edited as well.
2663- Setting: `linked_edits`
2664- Default: `true`
2665
2666**Options**
2667
2668`boolean` values
2669
2670## LSP Document Colors
2671
2672- Description: Whether to show document color information from the language server
2673- Setting: `lsp_document_colors`
2674- Default: `true`
2675
2676**Options**
2677
2678`boolean` values
2679
2680## Max Tabs
2681
2682- Description: Maximum number of tabs to show in the tab bar
2683- Setting: `max_tabs`
2684- Default: `null`
2685
2686**Options**
2687
2688Positive `integer` values or `null` for unlimited tabs
2689
2690## Middle Click Paste (Linux only)
2691
2692- Description: Enable middle-click paste on Linux
2693- Setting: `middle_click_paste`
2694- Default: `true`
2695
2696**Options**
2697
2698`boolean` values
2699
2700## Multi Cursor Modifier
2701
2702- 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.
2703- Setting: `multi_cursor_modifier`
2704- Default: `alt`
2705
2706**Options**
2707
27081. Maps to `Alt` on Linux and Windows and to `Option` on macOS:
2709
2710```json [settings]
2711{
2712 "multi_cursor_modifier": "alt"
2713}
2714```
2715
27162. Maps `Control` on Linux and Windows and to `Command` on macOS:
2717
2718```json [settings]
2719{
2720 "multi_cursor_modifier": "cmd_or_ctrl" // alias: "cmd", "ctrl"
2721}
2722```
2723
2724## Node
2725
2726- Description: Configuration for Node.js integration
2727- Setting: `node`
2728- Default:
2729
2730```json [settings]
2731{
2732 "node": {
2733 "ignore_system_version": false,
2734 "path": null,
2735 "npm_path": null
2736 }
2737}
2738```
2739
2740**Options**
2741
2742- `ignore_system_version`: Whether to ignore the system Node.js version
2743- `path`: Custom path to Node.js binary
2744- `npm_path`: Custom path to npm binary
2745
2746## Network Proxy
2747
2748- Description: Configure a network proxy for Zed.
2749- Setting: `proxy`
2750- Default: `null`
2751
2752**Options**
2753
2754The proxy setting must contain a URL to the proxy.
2755
2756The following URI schemes are supported:
2757
2758- `http`
2759- `https`
2760- `socks4` - SOCKS4 proxy with local DNS
2761- `socks4a` - SOCKS4 proxy with remote DNS
2762- `socks5` - SOCKS5 proxy with local DNS
2763- `socks5h` - SOCKS5 proxy with remote DNS
2764
2765`http` will be used when no scheme is specified.
2766
2767By 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`.
2768
2769For example, to set an `http` proxy, add the following to your settings:
2770
2771```json [settings]
2772{
2773 "proxy": "http://127.0.0.1:10809"
2774}
2775```
2776
2777Or to set a `socks5` proxy:
2778
2779```json [settings]
2780{
2781 "proxy": "socks5h://localhost:10808"
2782}
2783```
2784
2785If 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.
2786
2787## On Last Window Closed
2788
2789- Description: What to do when the last window is closed
2790- Setting: `on_last_window_closed`
2791- Default: `"platform_default"`
2792
2793**Options**
2794
27951. Use platform default behavior:
2796
2797```json [settings]
2798{
2799 "on_last_window_closed": "platform_default"
2800}
2801```
2802
28032. Always quit the application:
2804
2805```json [settings]
2806{
2807 "on_last_window_closed": "quit_app"
2808}
2809```
2810
2811## Profiles
2812
2813- Description: Configuration profiles that can be applied on top of existing settings
2814- Setting: `profiles`
2815- Default: `{}`
2816
2817**Options**
2818
2819Configuration object for defining settings profiles. Example:
2820
2821```json [settings]
2822{
2823 "profiles": {
2824 "presentation": {
2825 "buffer_font_size": 20,
2826 "ui_font_size": 18,
2827 "theme": "One Light"
2828 }
2829 }
2830}
2831```
2832
2833## Preview tabs
2834
2835- Description:
2836 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. \
2837 There are several ways to convert a preview tab into a regular tab:
2838
2839 - Double-clicking on the file
2840 - Double-clicking on the tab header
2841 - Using the {#action project_panel::OpenPermanent} action
2842 - Editing the file
2843 - Dragging the file to a different pane
2844
2845- Setting: `preview_tabs`
2846- Default:
2847
2848```json [settings]
2849"preview_tabs": {
2850 "enabled": true,
2851 "enable_preview_from_file_finder": false,
2852 "enable_preview_from_code_navigation": false,
2853}
2854```
2855
2856### Enable preview from file finder
2857
2858- Description: Determines whether to open files in preview mode when selected from the file finder.
2859- Setting: `enable_preview_from_file_finder`
2860- Default: `false`
2861
2862**Options**
2863
2864`boolean` values
2865
2866### Enable preview from code navigation
2867
2868- Description: Determines whether a preview tab gets replaced when code navigation is used to navigate away from the tab.
2869- Setting: `enable_preview_from_code_navigation`
2870- Default: `false`
2871
2872**Options**
2873
2874`boolean` values
2875
2876## File Finder
2877
2878### File Icons
2879
2880- Description: Whether to show file icons in the file finder.
2881- Setting: `file_icons`
2882- Default: `true`
2883
2884### Modal Max Width
2885
2886- Description: Max-width of the file finder modal. It can take one of these values: `small`, `medium`, `large`, `xlarge`, and `full`.
2887- Setting: `modal_max_width`
2888- Default: `small`
2889
2890### Skip Focus For Active In Search
2891
2892- Description: Determines whether the file finder should skip focus for the active file in search results.
2893- Setting: `skip_focus_for_active_in_search`
2894- Default: `true`
2895
2896## Pane Split Direction Horizontal
2897
2898- Description: The direction that you want to split panes horizontally
2899- Setting: `pane_split_direction_horizontal`
2900- Default: `"up"`
2901
2902**Options**
2903
29041. Split upward:
2905
2906```json [settings]
2907{
2908 "pane_split_direction_horizontal": "up"
2909}
2910```
2911
29122. Split downward:
2913
2914```json [settings]
2915{
2916 "pane_split_direction_horizontal": "down"
2917}
2918```
2919
2920## Pane Split Direction Vertical
2921
2922- Description: The direction that you want to split panes vertically
2923- Setting: `pane_split_direction_vertical`
2924- Default: `"left"`
2925
2926**Options**
2927
29281. Split to the left:
2929
2930```json [settings]
2931{
2932 "pane_split_direction_vertical": "left"
2933}
2934```
2935
29362. Split to the right:
2937
2938```json [settings]
2939{
2940 "pane_split_direction_vertical": "right"
2941}
2942```
2943
2944## Preferred Line Length
2945
2946- Description: The column at which to soft-wrap lines, for buffers where soft-wrap is enabled.
2947- Setting: `preferred_line_length`
2948- Default: `80`
2949
2950**Options**
2951
2952`integer` values
2953
2954## Private Files
2955
2956- Description: Globs to match against file paths to determine if a file is private
2957- Setting: `private_files`
2958- Default: `["**/.env*", "**/*.pem", "**/*.key", "**/*.cert", "**/*.crt", "**/secrets.yml"]`
2959
2960**Options**
2961
2962List of `string` glob patterns
2963
2964## Projects Online By Default
2965
2966- Description: Whether or not to show the online projects view by default.
2967- Setting: `projects_online_by_default`
2968- Default: `true`
2969
2970**Options**
2971
2972`boolean` values
2973
2974## Read SSH Config
2975
2976- Description: Whether to read SSH configuration files
2977- Setting: `read_ssh_config`
2978- Default: `true`
2979
2980**Options**
2981
2982`boolean` values
2983
2984## Redact Private Values
2985
2986- Description: Hide the values of variables from visual display in private files
2987- Setting: `redact_private_values`
2988- Default: `false`
2989
2990**Options**
2991
2992`boolean` values
2993
2994## Relative Line Numbers
2995
2996- Description: Whether to show relative line numbers in the gutter
2997- Setting: `relative_line_numbers`
2998- Default: `false`
2999
3000**Options**
3001
3002`boolean` values
3003
3004## Remove Trailing Whitespace On Save
3005
3006- Description: Whether or not to remove any trailing whitespace from lines of a buffer before saving it.
3007- Setting: `remove_trailing_whitespace_on_save`
3008- Default: `true`
3009
3010**Options**
3011
3012`boolean` values
3013
3014## Resize All Panels In Dock
3015
3016- Description: Whether to resize all the panels in a dock when resizing the dock. Can be a combination of "left", "right" and "bottom".
3017- Setting: `resize_all_panels_in_dock`
3018- Default: `["left"]`
3019
3020**Options**
3021
3022List of strings containing any combination of:
3023
3024- `"left"`: Resize left dock panels together
3025- `"right"`: Resize right dock panels together
3026- `"bottom"`: Resize bottom dock panels together
3027
3028## Restore on File Reopen
3029
3030- Description: Whether to attempt to restore previous file's state when opening it again. The state is stored per pane.
3031- Setting: `restore_on_file_reopen`
3032- Default: `true`
3033
3034**Options**
3035
3036`boolean` values
3037
3038## Restore on Startup
3039
3040- Description: Controls session restoration on startup.
3041- Setting: `restore_on_startup`
3042- Default: `last_session`
3043
3044**Options**
3045
30461. Restore all workspaces that were open when quitting Zed:
3047
3048```json [settings]
3049{
3050 "restore_on_startup": "last_session"
3051}
3052```
3053
30542. Restore the workspace that was closed last:
3055
3056```json [settings]
3057{
3058 "restore_on_startup": "last_workspace"
3059}
3060```
3061
30623. Always start with an empty editor:
3063
3064```json [settings]
3065{
3066 "restore_on_startup": "none"
3067}
3068```
3069
3070## Scroll Beyond Last Line
3071
3072- Description: Whether the editor will scroll beyond the last line
3073- Setting: `scroll_beyond_last_line`
3074- Default: `"one_page"`
3075
3076**Options**
3077
30781. Scroll one page beyond the last line by one page:
3079
3080```json [settings]
3081{
3082 "scroll_beyond_last_line": "one_page"
3083}
3084```
3085
30862. The editor will scroll beyond the last line by the same amount of lines as `vertical_scroll_margin`:
3087
3088```json [settings]
3089{
3090 "scroll_beyond_last_line": "vertical_scroll_margin"
3091}
3092```
3093
30943. The editor will not scroll beyond the last line:
3095
3096```json [settings]
3097{
3098 "scroll_beyond_last_line": "off"
3099}
3100```
3101
3102**Options**
3103
3104`boolean` values
3105
3106## Scroll Sensitivity
3107
3108- Description: Scroll sensitivity multiplier. This multiplier is applied to both the horizontal and vertical delta values while scrolling.
3109- Setting: `scroll_sensitivity`
3110- Default: `1.0`
3111
3112**Options**
3113
3114Positive `float` values
3115
3116### Fast Scroll Sensitivity
3117
3118- Description: Scroll sensitivity multiplier for fast scrolling. This multiplier is applied to both the horizontal and vertical delta values while scrolling. Fast scrolling happens when a user holds the alt or option key while scrolling.
3119- Setting: `fast_scroll_sensitivity`
3120- Default: `4.0`
3121
3122**Options**
3123
3124Positive `float` values
3125
3126### Horizontal Scroll Margin
3127
3128- Description: The number of characters to keep on either side when scrolling with the mouse
3129- Setting: `horizontal_scroll_margin`
3130- Default: `5`
3131
3132**Options**
3133
3134Non-negative `integer` values
3135
3136### Vertical Scroll Margin
3137
3138- Description: The number of lines to keep above/below the cursor when scrolling with the keyboard
3139- Setting: `vertical_scroll_margin`
3140- Default: `3`
3141
3142**Options**
3143
3144Non-negative `integer` values
3145
3146## Search
3147
3148- Description: Search options to enable by default when opening new project and buffer searches.
3149- Setting: `search`
3150- Default:
3151
3152```json [settings]
3153"search": {
3154 "whole_word": false,
3155 "case_sensitive": false,
3156 "include_ignored": false,
3157 "regex": false
3158},
3159```
3160
3161## Search Wrap
3162
3163- Description: If `search_wrap` is disabled, search result do not wrap around the end of the file
3164- Setting: `search_wrap`
3165- Default: `true`
3166
3167## Seed Search Query From Cursor
3168
3169- Description: When to populate a new search's query based on the text under the cursor.
3170- Setting: `seed_search_query_from_cursor`
3171- Default: `always`
3172
3173**Options**
3174
31751. `always` always populate the search query with the word under the cursor
31762. `selection` only populate the search query when there is text selected
31773. `never` never populate the search query
3178
3179## Use Smartcase Search
3180
3181- 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. \
3182 This applies to both in-file searches and project-wide searches.
3183- Setting: `use_smartcase_search`
3184- Default: `false`
3185
3186**Options**
3187
3188`boolean` values
3189
3190Examples:
3191
3192- Searching for "function" would match "function", "Function", "FUNCTION", etc.
3193- Searching for "Function" would only match "Function", not "function" or "FUNCTION"
3194
3195## Show Call Status Icon
3196
3197- Description: Whether or not to show the call status icon in the status bar.
3198- Setting: `show_call_status_icon`
3199- Default: `true`
3200
3201**Options**
3202
3203`boolean` values
3204
3205## Completions
3206
3207- Description: Controls how completions are processed for this language.
3208- Setting: `completions`
3209- Default:
3210
3211```json [settings]
3212{
3213 "completions": {
3214 "words": "fallback",
3215 "words_min_length": 3,
3216 "lsp": true,
3217 "lsp_fetch_timeout_ms": 0,
3218 "lsp_insert_mode": "replace_suffix"
3219 }
3220}
3221```
3222
3223### Words
3224
3225- Description: Controls how words are completed. For large documents, not all words may be fetched for completion.
3226- Setting: `words`
3227- Default: `fallback`
3228
3229**Options**
3230
32311. `enabled` - Always fetch document's words for completions along with LSP completions
32322. `fallback` - Only if LSP response errors or times out, use document's words to show completions
32333. `disabled` - Never fetch or complete document's words for completions (word-based completions can still be queried via a separate action)
3234
3235### Min Words Query Length
3236
3237- Description: Minimum number of characters required to automatically trigger word-based completions.
3238 Before that value, it's still possible to trigger the words-based completion manually with the corresponding editor command.
3239- Setting: `words_min_length`
3240- Default: `3`
3241
3242**Options**
3243
3244Positive integer values
3245
3246### LSP
3247
3248- Description: Whether to fetch LSP completions or not.
3249- Setting: `lsp`
3250- Default: `true`
3251
3252**Options**
3253
3254`boolean` values
3255
3256### LSP Fetch Timeout (ms)
3257
3258- Description: When fetching LSP completions, determines how long to wait for a response of a particular server. When set to 0, waits indefinitely.
3259- Setting: `lsp_fetch_timeout_ms`
3260- Default: `0`
3261
3262**Options**
3263
3264`integer` values representing milliseconds
3265
3266### LSP Insert Mode
3267
3268- Description: Controls what range to replace when accepting LSP completions.
3269- Setting: `lsp_insert_mode`
3270- Default: `replace_suffix`
3271
3272**Options**
3273
32741. `insert` - Replaces text before the cursor, using the `insert` range described in the LSP specification
32752. `replace` - Replaces text before and after the cursor, using the `replace` range described in the LSP specification
32763. `replace_subsequence` - Behaves like `"replace"` if the text that would be replaced is a subsequence of the completion text, and like `"insert"` otherwise
32774. `replace_suffix` - Behaves like `"replace"` if the text after the cursor is a suffix of the completion, and like `"insert"` otherwise
3278
3279## Show Completions On Input
3280
3281- Description: Whether or not to show completions as you type.
3282- Setting: `show_completions_on_input`
3283- Default: `true`
3284
3285**Options**
3286
3287`boolean` values
3288
3289## Show Completion Documentation
3290
3291- Description: Whether to display inline and alongside documentation for items in the completions menu.
3292- Setting: `show_completion_documentation`
3293- Default: `true`
3294
3295**Options**
3296
3297`boolean` values
3298
3299## Show Edit Predictions
3300
3301- Description: Whether to show edit predictions as you type or manually by triggering `editor::ShowEditPrediction`.
3302- Setting: `show_edit_predictions`
3303- Default: `true`
3304
3305**Options**
3306
3307`boolean` values
3308
3309## Show Whitespaces
3310
3311- Description: Whether or not to render whitespace characters in the editor.
3312- Setting: `show_whitespaces`
3313- Default: `selection`
3314
3315**Options**
3316
33171. `all`
33182. `selection`
33193. `none`
33204. `boundary`
3321
3322## Whitespace Map
3323
3324- Description: Specify the characters used to render whitespace when show_whitespaces is enabled.
3325- Setting: `whitespace_map`
3326- Default:
3327
3328```json [settings]
3329{
3330 "whitespace_map": {
3331 "space": "•",
3332 "tab": "→"
3333 }
3334}
3335```
3336
3337## Soft Wrap
3338
3339- Description: Whether or not to automatically wrap lines of text to fit editor / preferred width.
3340- Setting: `soft_wrap`
3341- Default: `none`
3342
3343**Options**
3344
33451. `none` to avoid wrapping generally, unless the line is too long
33462. `prefer_line` (deprecated, same as `none`)
33473. `editor_width` to wrap lines that overflow the editor width
33484. `preferred_line_length` to wrap lines that overflow `preferred_line_length` config value
33495. `bounded` to wrap lines at the minimum of `editor_width` and `preferred_line_length`
3350
3351## Show Wrap Guides
3352
3353- Description: Whether to show wrap guides (vertical rulers) in the editor. Setting this to true will show a guide at the 'preferred_line_length' value if 'soft_wrap' is set to 'preferred_line_length', and will show any additional guides as specified by the 'wrap_guides' setting.
3354- Setting: `show_wrap_guides`
3355- Default: `true`
3356
3357**Options**
3358
3359`boolean` values
3360
3361## Use On Type Format
3362
3363- Description: Whether to use additional LSP queries to format (and amend) the code after every "trigger" symbol input, defined by LSP server capabilities
3364- Setting: `use_on_type_format`
3365- Default: `true`
3366
3367**Options**
3368
3369`boolean` values
3370
3371## Use Auto Surround
3372
3373- Description: Whether to automatically surround selected text when typing opening parenthesis, bracket, brace, single or double quote characters. For example, when you select text and type '(', Zed will surround the text with ().
3374- Setting: `use_auto_surround`
3375- Default: `true`
3376
3377**Options**
3378
3379`boolean` values
3380
3381## Use System Path Prompts
3382
3383- Description: Whether to use the system provided dialogs for Open and Save As. When set to false, Zed will use the built-in keyboard-first pickers.
3384- Setting: `use_system_path_prompts`
3385- Default: `true`
3386
3387**Options**
3388
3389`boolean` values
3390
3391## Use System Prompts
3392
3393- Description: Whether to use the system provided dialogs for prompts, such as confirmation prompts. When set to false, Zed will use its built-in prompts. Note that on Linux, this option is ignored and Zed will always use the built-in prompts.
3394- Setting: `use_system_prompts`
3395- Default: `true`
3396
3397**Options**
3398
3399`boolean` values
3400
3401## Wrap Guides (Vertical Rulers)
3402
3403- Description: Where to display vertical rulers as wrap-guides. Disable by setting `show_wrap_guides` to `false`.
3404- Setting: `wrap_guides`
3405- Default: []
3406
3407**Options**
3408
3409List of `integer` column numbers
3410
3411## Tab Size
3412
3413- Description: The number of spaces to use for each tab character.
3414- Setting: `tab_size`
3415- Default: `4`
3416
3417**Options**
3418
3419`integer` values
3420
3421## Tasks
3422
3423- Description: Configuration for tasks that can be run within Zed
3424- Setting: `tasks`
3425- Default:
3426
3427```json [settings]
3428{
3429 "tasks": {
3430 "variables": {},
3431 "enabled": true,
3432 "prefer_lsp": false
3433 }
3434}
3435```
3436
3437**Options**
3438
3439- `variables`: Custom variables for task configuration
3440- `enabled`: Whether tasks are enabled
3441- `prefer_lsp`: Whether to prefer LSP-provided tasks over Zed language extension ones
3442
3443## Telemetry
3444
3445- Description: Control what info is collected by Zed.
3446- Setting: `telemetry`
3447- Default:
3448
3449```json [settings]
3450"telemetry": {
3451 "diagnostics": true,
3452 "metrics": true
3453},
3454```
3455
3456**Options**
3457
3458### Diagnostics
3459
3460- Description: Setting for sending debug-related data, such as crash reports.
3461- Setting: `diagnostics`
3462- Default: `true`
3463
3464**Options**
3465
3466`boolean` values
3467
3468### Metrics
3469
3470- Description: Setting for sending anonymized usage data, such what languages you're using Zed with.
3471- Setting: `metrics`
3472- Default: `true`
3473
3474**Options**
3475
3476`boolean` values
3477
3478## Terminal
3479
3480- Description: Configuration for the terminal.
3481- Setting: `terminal`
3482- Default:
3483
3484```json [settings]
3485{
3486 "terminal": {
3487 "alternate_scroll": "off",
3488 "blinking": "terminal_controlled",
3489 "copy_on_select": false,
3490 "keep_selection_on_copy": true,
3491 "dock": "bottom",
3492 "default_width": 640,
3493 "default_height": 320,
3494 "detect_venv": {
3495 "on": {
3496 "directories": [".env", "env", ".venv", "venv"],
3497 "activate_script": "default"
3498 }
3499 },
3500 "env": {},
3501 "font_family": null,
3502 "font_features": null,
3503 "font_size": null,
3504 "line_height": "comfortable",
3505 "minimum_contrast": 45,
3506 "option_as_meta": false,
3507 "button": true,
3508 "shell": "system",
3509 "toolbar": {
3510 "breadcrumbs": false
3511 },
3512 "working_directory": "current_project_directory",
3513 "scrollbar": {
3514 "show": null
3515 }
3516 }
3517}
3518```
3519
3520### Terminal: Dock
3521
3522- Description: Control the position of the dock
3523- Setting: `dock`
3524- Default: `bottom`
3525
3526**Options**
3527
3528`"bottom"`, `"left"` or `"right"`
3529
3530### Terminal: Alternate Scroll
3531
3532- 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.
3533- Setting: `alternate_scroll`
3534- Default: `off`
3535
3536**Options**
3537
35381. Default alternate scroll mode to off
3539
3540```json [settings]
3541{
3542 "terminal": {
3543 "alternate_scroll": "off"
3544 }
3545}
3546```
3547
35482. Default alternate scroll mode to on
3549
3550```json [settings]
3551{
3552 "terminal": {
3553 "alternate_scroll": "on"
3554 }
3555}
3556```
3557
3558### Terminal: Blinking
3559
3560- Description: Set the cursor blinking behavior in the terminal
3561- Setting: `blinking`
3562- Default: `terminal_controlled`
3563
3564**Options**
3565
35661. Never blink the cursor, ignore the terminal mode
3567
3568```json [settings]
3569{
3570 "terminal": {
3571 "blinking": "off"
3572 }
3573}
3574```
3575
35762. Default the cursor blink to off, but allow the terminal to turn blinking on
3577
3578```json [settings]
3579{
3580 "terminal": {
3581 "blinking": "terminal_controlled"
3582 }
3583}
3584```
3585
35863. Always blink the cursor, ignore the terminal mode
3587
3588```json [settings]
3589{
3590 "terminal": {
3591 "blinking": "on"
3592 }
3593}
3594```
3595
3596### Terminal: Copy On Select
3597
3598- Description: Whether or not selecting text in the terminal will automatically copy to the system clipboard.
3599- Setting: `copy_on_select`
3600- Default: `false`
3601
3602**Options**
3603
3604`boolean` values
3605
3606**Example**
3607
3608```json [settings]
3609{
3610 "terminal": {
3611 "copy_on_select": true
3612 }
3613}
3614```
3615
3616### Terminal: Cursor Shape
3617
3618- Description: Controls the visual shape of the cursor in the terminal. When not explicitly set, it defaults to a block shape.
3619- Setting: `cursor_shape`
3620- Default: `null` (defaults to block)
3621
3622**Options**
3623
36241. A block that surrounds the following character
3625
3626```json [settings]
3627{
3628 "terminal": {
3629 "cursor_shape": "block"
3630 }
3631}
3632```
3633
36342. A vertical bar
3635
3636```json [settings]
3637{
3638 "terminal": {
3639 "cursor_shape": "bar"
3640 }
3641}
3642```
3643
36443. An underline / underscore that runs along the following character
3645
3646```json [settings]
3647{
3648 "terminal": {
3649 "cursor_shape": "underline"
3650 }
3651}
3652```
3653
36544. A box drawn around the following character
3655
3656```json [settings]
3657{
3658 "terminal": {
3659 "cursor_shape": "hollow"
3660 }
3661}
3662```
3663
3664### Terminal: Keep Selection On Copy
3665
3666- Description: Whether or not to keep the selection in the terminal after copying text.
3667- Setting: `keep_selection_on_copy`
3668- Default: `true`
3669
3670**Options**
3671
3672`boolean` values
3673
3674**Example**
3675
3676```json [settings]
3677{
3678 "terminal": {
3679 "keep_selection_on_copy": false
3680 }
3681}
3682```
3683
3684### Terminal: Env
3685
3686- 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
3687- Setting: `env`
3688- Default: `{}`
3689
3690**Example**
3691
3692```json [settings]
3693{
3694 "terminal": {
3695 "env": {
3696 "ZED": "1",
3697 "KEY": "value1:value2"
3698 }
3699 }
3700}
3701```
3702
3703### Terminal: Font Size
3704
3705- Description: What font size to use for the terminal. When not set defaults to matching the editor's font size
3706- Setting: `font_size`
3707- Default: `null`
3708
3709**Options**
3710
3711`integer` values
3712
3713```json [settings]
3714{
3715 "terminal": {
3716 "font_size": 15
3717 }
3718}
3719```
3720
3721### Terminal: Font Family
3722
3723- Description: What font to use for the terminal. When not set, defaults to matching the editor's font.
3724- Setting: `font_family`
3725- Default: `null`
3726
3727**Options**
3728
3729The name of any font family installed on the user's system
3730
3731```json [settings]
3732{
3733 "terminal": {
3734 "font_family": "Berkeley Mono"
3735 }
3736}
3737```
3738
3739### Terminal: Font Features
3740
3741- Description: What font features to use for the terminal. When not set, defaults to matching the editor's font features.
3742- Setting: `font_features`
3743- Default: `null`
3744- Platform: macOS and Windows.
3745
3746**Options**
3747
3748See Buffer Font Features
3749
3750```json [settings]
3751{
3752 "terminal": {
3753 "font_features": {
3754 "calt": false
3755 // See Buffer Font Features for more features
3756 }
3757 }
3758}
3759```
3760
3761### Terminal: Line Height
3762
3763- Description: Set the terminal's line height.
3764- Setting: `line_height`
3765- Default: `standard`
3766
3767**Options**
3768
37691. Use a line height that's `comfortable` for reading, 1.618.
3770
3771```json [settings]
3772{
3773 "terminal": {
3774 "line_height": "comfortable"
3775 }
3776}
3777```
3778
37792. Use a `standard` line height, 1.3. This option is useful for TUIs, particularly if they use box characters. (default)
3780
3781```json [settings]
3782{
3783 "terminal": {
3784 "line_height": "standard"
3785 }
3786}
3787```
3788
37893. Use a custom line height.
3790
3791```json [settings]
3792{
3793 "terminal": {
3794 "line_height": {
3795 "custom": 2
3796 }
3797 }
3798}
3799```
3800
3801### Terminal: Minimum Contrast
3802
3803- 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.
3804- Setting: `minimum_contrast`
3805- Default: `45`
3806
3807**Options**
3808
3809`integer` values from 0 to 106. Common recommended values:
3810
3811- `0`: No contrast adjustment
3812- `45`: Minimum for large fluent text (default)
3813- `60`: Minimum for other content text
3814- `75`: Minimum for body text
3815- `90`: Preferred for body text
3816
3817```json [settings]
3818{
3819 "terminal": {
3820 "minimum_contrast": 45
3821 }
3822}
3823```
3824
3825### Terminal: Option As Meta
3826
3827- Description: Re-interprets the option keys to act like a 'meta' key, like in Emacs.
3828- Setting: `option_as_meta`
3829- Default: `false`
3830
3831**Options**
3832
3833`boolean` values
3834
3835```json [settings]
3836{
3837 "terminal": {
3838 "option_as_meta": true
3839 }
3840}
3841```
3842
3843### Terminal: Shell
3844
3845- Description: What shell to use when launching the terminal.
3846- Setting: `shell`
3847- Default: `system`
3848
3849**Options**
3850
38511. Use the system's default terminal configuration (usually the `/etc/passwd` file).
3852
3853```json [settings]
3854{
3855 "terminal": {
3856 "shell": "system"
3857 }
3858}
3859```
3860
38612. A program to launch:
3862
3863```json [settings]
3864{
3865 "terminal": {
3866 "shell": {
3867 "program": "sh"
3868 }
3869 }
3870}
3871```
3872
38733. A program with arguments:
3874
3875```json [settings]
3876{
3877 "terminal": {
3878 "shell": {
3879 "with_arguments": {
3880 "program": "/bin/bash",
3881 "args": ["--login"]
3882 }
3883 }
3884 }
3885}
3886```
3887
3888## Terminal: Detect Virtual Environments {#terminal-detect_venv}
3889
3890- 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.
3891- Setting: `detect_venv`
3892- Default:
3893
3894```json [settings]
3895{
3896 "terminal": {
3897 "detect_venv": {
3898 "on": {
3899 // Default directories to search for virtual environments, relative
3900 // to the current working directory. We recommend overriding this
3901 // in your project's settings, rather than globally.
3902 "directories": [".env", "env", ".venv", "venv"],
3903 // Can also be `csh`, `fish`, and `nushell`
3904 "activate_script": "default"
3905 }
3906 }
3907 }
3908}
3909```
3910
3911Disable with:
3912
3913```json [settings]
3914{
3915 "terminal": {
3916 "detect_venv": "off"
3917 }
3918}
3919```
3920
3921## Terminal: Toolbar
3922
3923- Description: Whether or not to show various elements in the terminal toolbar.
3924- Setting: `toolbar`
3925- Default:
3926
3927```json [settings]
3928{
3929 "terminal": {
3930 "toolbar": {
3931 "breadcrumbs": false
3932 }
3933 }
3934}
3935```
3936
3937**Options**
3938
3939At the moment, only the `breadcrumbs` option is available, it controls displaying of the terminal title that can be changed via `PROMPT_COMMAND`.
3940
3941If the terminal title is empty, the breadcrumbs won't be shown.
3942
3943The shell running in the terminal needs to be configured to emit the title.
3944
3945Example command to set the title: `echo -e "\e]2;New Title\007";`
3946
3947### Terminal: Button
3948
3949- Description: Control to show or hide the terminal button in the status bar
3950- Setting: `button`
3951- Default: `true`
3952
3953**Options**
3954
3955`boolean` values
3956
3957```json [settings]
3958{
3959 "terminal": {
3960 "button": false
3961 }
3962}
3963```
3964
3965### Terminal: Working Directory
3966
3967- Description: What working directory to use when launching the terminal.
3968- Setting: `working_directory`
3969- Default: `"current_project_directory"`
3970
3971**Options**
3972
39731. Use the current file's project directory. Will Fallback to the first project directory strategy if unsuccessful
3974
3975```json [settings]
3976{
3977 "terminal": {
3978 "working_directory": "current_project_directory"
3979 }
3980}
3981```
3982
39832. Use the first project in this workspace's directory. Will fallback to using this platform's home directory.
3984
3985```json [settings]
3986{
3987 "terminal": {
3988 "working_directory": "first_project_directory"
3989 }
3990}
3991```
3992
39933. Always use this platform's home directory (if we can find it)
3994
3995```json [settings]
3996{
3997 "terminal": {
3998 "working_directory": "always_home"
3999 }
4000}
4001```
4002
40034. 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.
4004
4005```json [settings]
4006{
4007 "terminal": {
4008 "working_directory": {
4009 "always": {
4010 "directory": "~/zed/projects/"
4011 }
4012 }
4013 }
4014}
4015```
4016
4017## REPL
4018
4019- Description: Repl settings.
4020- Setting: `repl`
4021- Default:
4022
4023```json [settings]
4024"repl": {
4025 // Maximum number of columns to keep in REPL's scrollback buffer.
4026 // Clamped with [20, 512] range.
4027 "max_columns": 128,
4028 // Maximum number of lines to keep in REPL's scrollback buffer.
4029 // Clamped with [4, 256] range.
4030 "max_lines": 32
4031},
4032```
4033
4034## Theme
4035
4036- 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.
4037- Setting: `theme`
4038- Default: `One Dark`
4039
4040### Theme Object
4041
4042- Description: Specify the theme using an object that includes the `mode`, `dark`, and `light` themes.
4043- Setting: `theme`
4044- Default:
4045
4046```json [settings]
4047"theme": {
4048 "mode": "system",
4049 "dark": "One Dark",
4050 "light": "One Light"
4051},
4052```
4053
4054### Mode
4055
4056- Description: Specify theme mode.
4057- Setting: `mode`
4058- Default: `system`
4059
4060**Options**
4061
40621. Set the theme to dark mode
4063
4064```json [settings]
4065{
4066 "mode": "dark"
4067}
4068```
4069
40702. Set the theme to light mode
4071
4072```json [settings]
4073{
4074 "mode": "light"
4075}
4076```
4077
40783. Set the theme to system mode
4079
4080```json [settings]
4081{
4082 "mode": "system"
4083}
4084```
4085
4086### Dark
4087
4088- Description: The name of the dark Zed theme to use for the UI.
4089- Setting: `dark`
4090- Default: `One Dark`
4091
4092**Options**
4093
4094Run the {#action theme_selector::Toggle} action in the command palette to see a current list of valid themes names.
4095
4096### Light
4097
4098- Description: The name of the light Zed theme to use for the UI.
4099- Setting: `light`
4100- Default: `One Light`
4101
4102**Options**
4103
4104Run the {#action theme_selector::Toggle} action in the command palette to see a current list of valid themes names.
4105
4106## Title Bar
4107
4108- Description: Whether or not to show various elements in the title bar
4109- Setting: `title_bar`
4110- Default:
4111
4112```json [settings]
4113"title_bar": {
4114 "show_branch_icon": false,
4115 "show_branch_name": true,
4116 "show_project_items": true,
4117 "show_onboarding_banner": true,
4118 "show_user_picture": true,
4119 "show_sign_in": true,
4120 "show_menus": false
4121}
4122```
4123
4124**Options**
4125
4126- `show_branch_icon`: Whether to show the branch icon beside branch switcher in the titlebar
4127- `show_branch_name`: Whether to show the branch name button in the titlebar
4128- `show_project_items`: Whether to show the project host and name in the titlebar
4129- `show_onboarding_banner`: Whether to show onboarding banners in the titlebar
4130- `show_user_picture`: Whether to show user picture in the titlebar
4131- `show_sign_in`: Whether to show the sign in button in the titlebar
4132- `show_menus`: Whether to show the menus in the titlebar
4133
4134## Vim
4135
4136- Description: Whether or not to enable vim mode.
4137- Setting: `vim_mode`
4138- Default: `false`
4139
4140## When Closing With No Tabs
4141
4142- Description: Whether the window should be closed when using 'close active item' on a window with no tabs
4143- Setting: `when_closing_with_no_tabs`
4144- Default: `"platform_default"`
4145
4146**Options**
4147
41481. Use platform default behavior:
4149
4150```json [settings]
4151{
4152 "when_closing_with_no_tabs": "platform_default"
4153}
4154```
4155
41562. Always close the window:
4157
4158```json [settings]
4159{
4160 "when_closing_with_no_tabs": "close_window"
4161}
4162```
4163
41643. Never close the window:
4165
4166```json [settings]
4167{
4168 "when_closing_with_no_tabs": "keep_window_open"
4169}
4170```
4171
4172## Project Panel
4173
4174- Description: Customize project panel
4175- Setting: `project_panel`
4176- Default:
4177
4178```json [settings]
4179{
4180 "project_panel": {
4181 "button": true,
4182 "default_width": 240,
4183 "dock": "left",
4184 "entry_spacing": "comfortable",
4185 "file_icons": true,
4186 "folder_icons": true,
4187 "git_status": true,
4188 "indent_size": 20,
4189 "auto_reveal_entries": true,
4190 "auto_fold_dirs": true,
4191 "drag_and_drop": true,
4192 "scrollbar": {
4193 "show": null
4194 },
4195 "sticky_scroll": true,
4196 "show_diagnostics": "all",
4197 "indent_guides": {
4198 "show": "always"
4199 },
4200 "hide_root": false,
4201 "hide_hidden": false,
4202 "starts_open": true,
4203 "open_file_on_paste": true
4204 }
4205}
4206```
4207
4208### Dock
4209
4210- Description: Control the position of the dock
4211- Setting: `dock`
4212- Default: `left`
4213
4214**Options**
4215
42161. Default dock position to left
4217
4218```json [settings]
4219{
4220 "dock": "left"
4221}
4222```
4223
42242. Default dock position to right
4225
4226```json [settings]
4227{
4228 "dock": "right"
4229}
4230```
4231
4232### Entry Spacing
4233
4234- Description: Spacing between worktree entries
4235- Setting: `entry_spacing`
4236- Default: `comfortable`
4237
4238**Options**
4239
42401. Comfortable entry spacing
4241
4242```json [settings]
4243{
4244 "entry_spacing": "comfortable"
4245}
4246```
4247
42482. Standard entry spacing
4249
4250```json [settings]
4251{
4252 "entry_spacing": "standard"
4253}
4254```
4255
4256### Git Status
4257
4258- Description: Indicates newly created and updated files
4259- Setting: `git_status`
4260- Default: `true`
4261
4262**Options**
4263
42641. Default enable git status
4265
4266```json [settings]
4267{
4268 "git_status": true
4269}
4270```
4271
42722. Default disable git status
4273
4274```json [settings]
4275{
4276 "git_status": false
4277}
4278```
4279
4280### Default Width
4281
4282- Description: Customize default width taken by project panel
4283- Setting: `default_width`
4284- Default: `240`
4285
4286**Options**
4287
4288`float` values
4289
4290### Auto Reveal Entries
4291
4292- Description: Whether to reveal it in the project panel automatically, when a corresponding project entry becomes active. Gitignored entries are never auto revealed.
4293- Setting: `auto_reveal_entries`
4294- Default: `true`
4295
4296**Options**
4297
42981. Enable auto reveal entries
4299
4300```json [settings]
4301{
4302 "auto_reveal_entries": true
4303}
4304```
4305
43062. Disable auto reveal entries
4307
4308```json [settings]
4309{
4310 "auto_reveal_entries": false
4311}
4312```
4313
4314### Auto Fold Dirs
4315
4316- Description: Whether to fold directories automatically when directory has only one directory inside.
4317- Setting: `auto_fold_dirs`
4318- Default: `true`
4319
4320**Options**
4321
43221. Enable auto fold dirs
4323
4324```json [settings]
4325{
4326 "auto_fold_dirs": true
4327}
4328```
4329
43302. Disable auto fold dirs
4331
4332```json [settings]
4333{
4334 "auto_fold_dirs": false
4335}
4336```
4337
4338### Indent Size
4339
4340- Description: Amount of indentation (in pixels) for nested items.
4341- Setting: `indent_size`
4342- Default: `20`
4343
4344### Indent Guides: Show
4345
4346- Description: Whether to show indent guides in the project panel.
4347- Setting: `indent_guides`
4348- Default:
4349
4350```json [settings]
4351"indent_guides": {
4352 "show": "always"
4353}
4354```
4355
4356**Options**
4357
43581. Show indent guides in the project panel
4359
4360```json [settings]
4361{
4362 "indent_guides": {
4363 "show": "always"
4364 }
4365}
4366```
4367
43682. Hide indent guides in the project panel
4369
4370```json [settings]
4371{
4372 "indent_guides": {
4373 "show": "never"
4374 }
4375}
4376```
4377
4378### Scrollbar: Show
4379
4380- 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.
4381- Setting: `scrollbar`
4382- Default:
4383
4384```json [settings]
4385"scrollbar": {
4386 "show": null
4387}
4388```
4389
4390**Options**
4391
43921. Show scrollbar in the project panel
4393
4394```json [settings]
4395{
4396 "scrollbar": {
4397 "show": "always"
4398 }
4399}
4400```
4401
44022. Hide scrollbar in the project panel
4403
4404```json [settings]
4405{
4406 "scrollbar": {
4407 "show": "never"
4408 }
4409}
4410```
4411
4412## Agent
4413
4414Visit [the Configuration page](./ai/configuration.md) under the AI section to learn more about all the agent-related settings.
4415
4416## Collaboration Panel
4417
4418- Description: Customizations for the collaboration panel.
4419- Setting: `collaboration_panel`
4420- Default:
4421
4422```json [settings]
4423{
4424 "collaboration_panel": {
4425 "button": true,
4426 "dock": "left",
4427 "default_width": 240
4428 }
4429}
4430```
4431
4432**Options**
4433
4434- `button`: Whether to show the collaboration panel button in the status bar
4435- `dock`: Where to dock the collaboration panel. Can be `left` or `right`
4436- `default_width`: Default width of the collaboration panel
4437
4438## Debugger
4439
4440- Description: Configuration for debugger panel and settings
4441- Setting: `debugger`
4442- Default:
4443
4444```json [settings]
4445{
4446 "debugger": {
4447 "stepping_granularity": "line",
4448 "save_breakpoints": true,
4449 "dock": "bottom",
4450 "button": true
4451 }
4452}
4453```
4454
4455See the [debugger page](./debugger.md) for more information about debugging support within Zed.
4456
4457## Git Panel
4458
4459- Description: Setting to customize the behavior of the git panel.
4460- Setting: `git_panel`
4461- Default:
4462
4463```json [settings]
4464{
4465 "git_panel": {
4466 "button": true,
4467 "dock": "left",
4468 "default_width": 360,
4469 "status_style": "icon",
4470 "fallback_branch_name": "main",
4471 "sort_by_path": false,
4472 "collapse_untracked_diff": false,
4473 "scrollbar": {
4474 "show": null
4475 }
4476 }
4477}
4478```
4479
4480**Options**
4481
4482- `button`: Whether to show the git panel button in the status bar
4483- `dock`: Where to dock the git panel. Can be `left` or `right`
4484- `default_width`: Default width of the git panel
4485- `status_style`: How to display git status. Can be `label_color` or `icon`
4486- `fallback_branch_name`: What branch name to use if `init.defaultBranch` is not set
4487- `sort_by_path`: Whether to sort entries in the panel by path or by status (the default)
4488- `collapse_untracked_diff`: Whether to collapse untracked files in the diff panel
4489- `scrollbar`: When to show the scrollbar in the git panel
4490
4491## Outline Panel
4492
4493- Description: Customize outline Panel
4494- Setting: `outline_panel`
4495- Default:
4496
4497```json [settings]
4498"outline_panel": {
4499 "button": true,
4500 "default_width": 300,
4501 "dock": "left",
4502 "file_icons": true,
4503 "folder_icons": true,
4504 "git_status": true,
4505 "indent_size": 20,
4506 "auto_reveal_entries": true,
4507 "auto_fold_dirs": true,
4508 "indent_guides": {
4509 "show": "always"
4510 },
4511 "scrollbar": {
4512 "show": null
4513 }
4514}
4515```
4516
4517## Calls
4518
4519- Description: Customize behavior when participating in a call
4520- Setting: `calls`
4521- Default:
4522
4523```json [settings]
4524"calls": {
4525 // Join calls with the microphone live by default
4526 "mute_on_join": false,
4527 // Share your project when you are the first to join a channel
4528 "share_on_join": false
4529},
4530```
4531
4532## Unnecessary Code Fade
4533
4534- Description: How much to fade out unused code.
4535- Setting: `unnecessary_code_fade`
4536- Default: `0.3`
4537
4538**Options**
4539
4540Float values between `0.0` and `0.9`, where:
4541
4542- `0.0` means no fading (unused code looks the same as used code)
4543- `0.9` means maximum fading (unused code is very faint but still visible)
4544
4545**Example**
4546
4547```json [settings]
4548{
4549 "unnecessary_code_fade": 0.5
4550}
4551```
4552
4553## UI Font Family
4554
4555- Description: The name of the font to use for text in the UI.
4556- Setting: `ui_font_family`
4557- Default: `.ZedSans`. This currently aliases to [IBM Plex](https://www.ibm.com/plex/).
4558
4559**Options**
4560
4561The 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).
4562
4563## UI Font Features
4564
4565- Description: The OpenType features to enable for text in the UI.
4566- Setting: `ui_font_features`
4567- Default:
4568
4569```json [settings]
4570"ui_font_features": {
4571 "calt": false
4572}
4573```
4574
4575- Platform: macOS and Windows.
4576
4577**Options**
4578
4579Zed supports all OpenType features that can be enabled or disabled for a given UI font, as well as setting values for font features.
4580
4581For example, to disable font ligatures, add the following to your settings:
4582
4583```json [settings]
4584{
4585 "ui_font_features": {
4586 "calt": false
4587 }
4588}
4589```
4590
4591You can also set other OpenType features, like setting `cv01` to `7`:
4592
4593```json [settings]
4594{
4595 "ui_font_features": {
4596 "cv01": 7
4597 }
4598}
4599```
4600
4601## UI Font Fallbacks
4602
4603- Description: The font fallbacks to use for text in the UI.
4604- Setting: `ui_font_fallbacks`
4605- Default: `null`
4606- Platform: macOS and Windows.
4607
4608**Options**
4609
4610For example, to use `Nerd Font` as a fallback, add the following to your settings:
4611
4612```json [settings]
4613{
4614 "ui_font_fallbacks": ["Nerd Font"]
4615}
4616```
4617
4618## UI Font Size
4619
4620- Description: The default font size for text in the UI.
4621- Setting: `ui_font_size`
4622- Default: `16`
4623
4624**Options**
4625
4626`integer` values from `6` to `100` pixels (inclusive)
4627
4628## UI Font Weight
4629
4630- Description: The default font weight for text in the UI.
4631- Setting: `ui_font_weight`
4632- Default: `400`
4633
4634**Options**
4635
4636`integer` values between `100` and `900`
4637
4638## An example configuration:
4639
4640```json [settings]
4641// ~/.config/zed/settings.json
4642{
4643 "theme": "cave-light",
4644 "tab_size": 2,
4645 "preferred_line_length": 80,
4646 "soft_wrap": "none",
4647
4648 "buffer_font_size": 18,
4649 "buffer_font_family": ".ZedMono",
4650
4651 "autosave": "on_focus_change",
4652 "format_on_save": "off",
4653 "vim_mode": false,
4654 "projects_online_by_default": true,
4655 "terminal": {
4656 "font_family": "FiraCode Nerd Font Mono",
4657 "blinking": "off"
4658 },
4659 "languages": {
4660 "C": {
4661 "format_on_save": "on",
4662 "formatter": "language_server",
4663 "preferred_line_length": 64,
4664 "soft_wrap": "preferred_line_length"
4665 }
4666 }
4667}
4668```