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_extensions`
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
932Cursor indicators appear as small marks on the scrollbar showing where other collaborators' cursors are positioned in the file.
933
934**Options**
935
936`boolean` values
937
938### Git Diff Indicators
939
940- Description: Whether to show git diff indicators in the scrollbar.
941- Setting: `git_diff`
942- Default: `true`
943
944Git diff indicators appear as colored marks showing lines that have been added, modified, or deleted compared to the git HEAD.
945
946**Options**
947
948`boolean` values
949
950### Search Results Indicators
951
952- Description: Whether to show buffer search results in the scrollbar.
953- Setting: `search_results`
954- Default: `true`
955
956Search result indicators appear as marks showing all locations in the file where your current search query matches.
957
958**Options**
959
960`boolean` values
961
962### Selected Text Indicators
963
964- Description: Whether to show selected text occurrences in the scrollbar.
965- Setting: `selected_text`
966- Default: `true`
967
968Selected text indicators appear as marks showing all occurrences of the currently selected text throughout the file.
969
970**Options**
971
972`boolean` values
973
974### Selected Symbols Indicators
975
976- Description: Whether to show selected symbol occurrences in the scrollbar.
977- Setting: `selected_symbol`
978- Default: `true`
979
980Selected symbol indicators appear as marks showing all occurrences of the currently selected symbol (like a function or variable name) throughout the file.
981
982**Options**
983
984`boolean` values
985
986### Diagnostics
987
988- Description: Which diagnostic indicators to show in the scrollbar.
989- Setting: `diagnostics`
990- Default: `all`
991
992Diagnostic indicators appear as colored marks showing errors, warnings, and other language server diagnostics at their corresponding line positions in the file.
993
994**Options**
995
9961. Show all diagnostics:
997
998```json [settings]
999{
1000 "show_diagnostics": "all"
1001}
1002```
1003
10042. Do not show any diagnostics:
1005
1006```json [settings]
1007{
1008 "show_diagnostics": "off"
1009}
1010```
1011
10123. Show only errors:
1013
1014```json [settings]
1015{
1016 "show_diagnostics": "error"
1017}
1018```
1019
10204. Show only errors and warnings:
1021
1022```json [settings]
1023{
1024 "show_diagnostics": "warning"
1025}
1026```
1027
10285. Show only errors, warnings, and information:
1029
1030```json [settings]
1031{
1032 "show_diagnostics": "info"
1033}
1034```
1035
1036### Axes
1037
1038- Description: Forcefully enable or disable the scrollbar for each axis
1039- Setting: `axes`
1040- Default:
1041
1042```json [settings]
1043"scrollbar": {
1044 "axes": {
1045 "horizontal": true,
1046 "vertical": true,
1047 },
1048}
1049```
1050
1051#### Horizontal
1052
1053- Description: When false, forcefully disables the horizontal scrollbar. Otherwise, obey other settings.
1054- Setting: `horizontal`
1055- Default: `true`
1056
1057**Options**
1058
1059`boolean` values
1060
1061#### Vertical
1062
1063- Description: When false, forcefully disables the vertical scrollbar. Otherwise, obey other settings.
1064- Setting: `vertical`
1065- Default: `true`
1066
1067**Options**
1068
1069`boolean` values
1070
1071## Minimap
1072
1073- Description: Settings related to the editor's minimap, which provides an overview of your document.
1074- Setting: `minimap`
1075- Default:
1076
1077```json [settings]
1078{
1079 "minimap": {
1080 "show": "never",
1081 "thumb": "always",
1082 "thumb_border": "left_open",
1083 "current_line_highlight": null
1084 }
1085}
1086```
1087
1088### Show Mode
1089
1090- Description: When to show the minimap in the editor.
1091- Setting: `show`
1092- Default: `never`
1093
1094**Options**
1095
10961. Always show the minimap:
1097
1098```json [settings]
1099{
1100 "show": "always"
1101}
1102```
1103
11042. Show the minimap if the editor's scrollbars are visible:
1105
1106```json [settings]
1107{
1108 "show": "auto"
1109}
1110```
1111
11123. Never show the minimap:
1113
1114```json [settings]
1115{
1116 "show": "never"
1117}
1118```
1119
1120### Thumb Display
1121
1122- Description: When to show the minimap thumb (the visible editor area) in the minimap.
1123- Setting: `thumb`
1124- Default: `always`
1125
1126**Options**
1127
11281. Show the minimap thumb when hovering over the minimap:
1129
1130```json [settings]
1131{
1132 "thumb": "hover"
1133}
1134```
1135
11362. Always show the minimap thumb:
1137
1138```json [settings]
1139{
1140 "thumb": "always"
1141}
1142```
1143
1144### Thumb Border
1145
1146- Description: How the minimap thumb border should look.
1147- Setting: `thumb_border`
1148- Default: `left_open`
1149
1150**Options**
1151
11521. Display a border on all sides of the thumb:
1153
1154```json [settings]
1155{
1156 "thumb_border": "full"
1157}
1158```
1159
11602. Display a border on all sides except the left side:
1161
1162```json [settings]
1163{
1164 "thumb_border": "left_open"
1165}
1166```
1167
11683. Display a border on all sides except the right side:
1169
1170```json [settings]
1171{
1172 "thumb_border": "right_open"
1173}
1174```
1175
11764. Display a border only on the left side:
1177
1178```json [settings]
1179{
1180 "thumb_border": "left_only"
1181}
1182```
1183
11845. Display the thumb without any border:
1185
1186```json [settings]
1187{
1188 "thumb_border": "none"
1189}
1190```
1191
1192### Current Line Highlight
1193
1194- Description: How to highlight the current line in the minimap.
1195- Setting: `current_line_highlight`
1196- Default: `null`
1197
1198**Options**
1199
12001. Inherit the editor's current line highlight setting:
1201
1202```json [settings]
1203{
1204 "minimap": {
1205 "current_line_highlight": null
1206 }
1207}
1208```
1209
12102. Highlight the current line in the minimap:
1211
1212```json [settings]
1213{
1214 "minimap": {
1215 "current_line_highlight": "line"
1216 }
1217}
1218```
1219
1220or
1221
1222```json [settings]
1223{
1224 "minimap": {
1225 "current_line_highlight": "all"
1226 }
1227}
1228```
1229
12303. Do not highlight the current line in the minimap:
1231
1232```json [settings]
1233{
1234 "minimap": {
1235 "current_line_highlight": "gutter"
1236 }
1237}
1238```
1239
1240or
1241
1242```json [settings]
1243{
1244 "minimap": {
1245 "current_line_highlight": "none"
1246 }
1247}
1248```
1249
1250## Editor Tab Bar
1251
1252- Description: Settings related to the editor's tab bar.
1253- Settings: `tab_bar`
1254- Default:
1255
1256```json [settings]
1257"tab_bar": {
1258 "show": true,
1259 "show_nav_history_buttons": true,
1260 "show_tab_bar_buttons": true
1261}
1262```
1263
1264### Show
1265
1266- Description: Whether or not to show the tab bar in the editor.
1267- Setting: `show`
1268- Default: `true`
1269
1270**Options**
1271
1272`boolean` values
1273
1274### Navigation History Buttons
1275
1276- Description: Whether or not to show the navigation history buttons.
1277- Setting: `show_nav_history_buttons`
1278- Default: `true`
1279
1280**Options**
1281
1282`boolean` values
1283
1284### Tab Bar Buttons
1285
1286- Description: Whether or not to show the tab bar buttons.
1287- Setting: `show_tab_bar_buttons`
1288- Default: `true`
1289
1290**Options**
1291
1292`boolean` values
1293
1294## Editor Tabs
1295
1296- Description: Configuration for the editor tabs.
1297- Setting: `tabs`
1298- Default:
1299
1300```json [settings]
1301"tabs": {
1302 "close_position": "right",
1303 "file_icons": false,
1304 "git_status": false,
1305 "activate_on_close": "history",
1306 "show_close_button": "hover",
1307 "show_diagnostics": "off"
1308},
1309```
1310
1311### Close Position
1312
1313- Description: Where to display close button within a tab.
1314- Setting: `close_position`
1315- Default: `right`
1316
1317**Options**
1318
13191. Display the close button on the right:
1320
1321```json [settings]
1322{
1323 "close_position": "right"
1324}
1325```
1326
13272. Display the close button on the left:
1328
1329```json [settings]
1330{
1331 "close_position": "left"
1332}
1333```
1334
1335### File Icons
1336
1337- Description: Whether to show the file icon for a tab.
1338- Setting: `file_icons`
1339- Default: `false`
1340
1341### Git Status
1342
1343- Description: Whether or not to show Git file status in tab.
1344- Setting: `git_status`
1345- Default: `false`
1346
1347### Activate on close
1348
1349- Description: What to do after closing the current tab.
1350- Setting: `activate_on_close`
1351- Default: `history`
1352
1353**Options**
1354
13551. Activate the tab that was open previously:
1356
1357```json [settings]
1358{
1359 "activate_on_close": "history"
1360}
1361```
1362
13632. Activate the right neighbour tab if present:
1364
1365```json [settings]
1366{
1367 "activate_on_close": "neighbour"
1368}
1369```
1370
13713. Activate the left neighbour tab if present:
1372
1373```json [settings]
1374{
1375 "activate_on_close": "left_neighbour"
1376}
1377```
1378
1379### Show close button
1380
1381- Description: Controls the appearance behavior of the tab's close button.
1382- Setting: `show_close_button`
1383- Default: `hover`
1384
1385**Options**
1386
13871. Show it just upon hovering the tab:
1388
1389```json [settings]
1390{
1391 "show_close_button": "hover"
1392}
1393```
1394
13952. Show it persistently:
1396
1397```json [settings]
1398{
1399 "show_close_button": "always"
1400}
1401```
1402
14033. Never show it, even if hovering it:
1404
1405```json [settings]
1406{
1407 "show_close_button": "hidden"
1408}
1409```
1410
1411### Show Diagnostics
1412
1413- 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.
1414- Setting: `show_diagnostics`
1415- Default: `off`
1416
1417**Options**
1418
14191. Do not mark any files:
1420
1421```json [settings]
1422{
1423 "show_diagnostics": "off"
1424}
1425```
1426
14272. Only mark files with errors:
1428
1429```json [settings]
1430{
1431 "show_diagnostics": "errors"
1432}
1433```
1434
14353. Mark files with errors and warnings:
1436
1437```json [settings]
1438{
1439 "show_diagnostics": "all"
1440}
1441```
1442
1443### Show Inline Code Actions
1444
1445- Description: Whether to show code action button at start of buffer line.
1446- Setting: `inline_code_actions`
1447- Default: `true`
1448
1449**Options**
1450
1451`boolean` values
1452
1453### Drag And Drop Selection
1454
1455- 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.
1456- Setting: `drag_and_drop_selection`
1457- Default:
1458
1459```json [settings]
1460"drag_and_drop_selection": {
1461 "enabled": true,
1462 "delay": 300
1463}
1464```
1465
1466## Editor Toolbar
1467
1468- Description: Whether or not to show various elements in the editor toolbar.
1469- Setting: `toolbar`
1470- Default:
1471
1472```json [settings]
1473"toolbar": {
1474 "breadcrumbs": true,
1475 "quick_actions": true,
1476 "selections_menu": true,
1477 "agent_review": true,
1478 "code_actions": false
1479},
1480```
1481
1482**Options**
1483
1484Each option controls displaying of a particular toolbar element. If all elements are hidden, the editor toolbar is not displayed.
1485
1486## Use System Tabs
1487
1488- Description: Whether to allow windows to tab together based on the user’s tabbing preference (macOS only).
1489- Setting: `use_system_window_tabs`
1490- Default: `false`
1491
1492**Options**
1493
1494This 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.
1495
1496## Enable Language Server
1497
1498- Description: Whether or not to use language servers to provide code intelligence.
1499- Setting: `enable_language_server`
1500- Default: `true`
1501
1502**Options**
1503
1504`boolean` values
1505
1506## Ensure Final Newline On Save
1507
1508- Description: Removes any lines containing only whitespace at the end of the file and ensures just one newline at the end.
1509- Setting: `ensure_final_newline_on_save`
1510- Default: `true`
1511
1512**Options**
1513
1514`boolean` values
1515
1516## Expand Excerpt Lines
1517
1518- Description: The default number of lines to expand excerpts in the multibuffer by
1519- Setting: `expand_excerpt_lines`
1520- Default: `5`
1521
1522**Options**
1523
1524Positive `integer` values
1525
1526## Excerpt Context Lines
1527
1528- Description: The number of lines of context to provide when showing excerpts in the multibuffer.
1529- Setting: `excerpt_context_lines`
1530- Default: `2`
1531
1532**Options**
1533
1534Positive `integer` value between 1 and 32. Values outside of this range will be clamped to this range.
1535
1536## Extend Comment On Newline
1537
1538- Description: Whether to start a new line with a comment when a previous line is a comment as well.
1539- Setting: `extend_comment_on_newline`
1540- Default: `true`
1541
1542**Options**
1543
1544`boolean` values
1545
1546## Status Bar
1547
1548- Description: Control various elements in the status bar. Note that some items in the status bar have their own settings set elsewhere.
1549- Setting: `status_bar`
1550- Default:
1551
1552```json [settings]
1553"status_bar": {
1554 "active_language_button": true,
1555 "cursor_position_button": true,
1556 "line_endings_button": false
1557},
1558```
1559
1560There 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.
1561
1562```json
1563"status_bar": {
1564 "experimental.show": false
1565}
1566```
1567
1568## LSP
1569
1570- Description: Configuration for language servers.
1571- Setting: `lsp`
1572- Default: `null`
1573
1574**Options**
1575
1576The following settings can be overridden for specific language servers:
1577
1578- `initialization_options`
1579- `settings`
1580
1581To override configuration for a language server, add an entry for that language server's name to the `lsp` value.
1582
1583Some 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.
1584
1585For example to pass the `check` option to `rust-analyzer`, use the following configuration:
1586
1587```json [settings]
1588"lsp": {
1589 "rust-analyzer": {
1590 "initialization_options": {
1591 "check": {
1592 "command": "clippy" // rust-analyzer.check.command (default: "check")
1593 }
1594 }
1595 }
1596}
1597```
1598
1599While other options may be changed at a runtime and should be placed under `settings`:
1600
1601```json [settings]
1602"lsp": {
1603 "yaml-language-server": {
1604 "settings": {
1605 "yaml": {
1606 "keyOrdering": true // Enforces alphabetical ordering of keys in maps
1607 }
1608 }
1609 }
1610}
1611```
1612
1613## Global LSP Settings
1614
1615- Description: Configuration for global LSP settings that apply to all language servers
1616- Setting: `global_lsp_settings`
1617- Default:
1618
1619```json [settings]
1620{
1621 "global_lsp_settings": {
1622 "button": true
1623 }
1624}
1625```
1626
1627**Options**
1628
1629- `button`: Whether to show the LSP status button in the status bar
1630
1631## LSP Highlight Debounce
1632
1633- Description: The debounce delay in milliseconds before querying highlights from the language server based on the current cursor location.
1634- Setting: `lsp_highlight_debounce`
1635- Default: `75`
1636
1637**Options**
1638
1639`integer` values representing milliseconds
1640
1641## Features
1642
1643- Description: Features that can be globally enabled or disabled
1644- Setting: `features`
1645- Default:
1646
1647```json [settings]
1648{
1649 "features": {
1650 "edit_prediction_provider": "zed"
1651 }
1652}
1653```
1654
1655### Edit Prediction Provider
1656
1657- Description: Which edit prediction provider to use
1658- Setting: `edit_prediction_provider`
1659- Default: `"zed"`
1660
1661**Options**
1662
16631. Use Zeta as the edit prediction provider:
1664
1665```json [settings]
1666{
1667 "features": {
1668 "edit_prediction_provider": "zed"
1669 }
1670}
1671```
1672
16732. Use Copilot as the edit prediction provider:
1674
1675```json [settings]
1676{
1677 "features": {
1678 "edit_prediction_provider": "copilot"
1679 }
1680}
1681```
1682
16833. Use Supermaven as the edit prediction provider:
1684
1685```json [settings]
1686{
1687 "features": {
1688 "edit_prediction_provider": "supermaven"
1689 }
1690}
1691```
1692
16934. Turn off edit predictions across all providers
1694
1695```json [settings]
1696{
1697 "features": {
1698 "edit_prediction_provider": "none"
1699 }
1700}
1701```
1702
1703## Format On Save
1704
1705- Description: Whether or not to perform a buffer format before saving.
1706- Setting: `format_on_save`
1707- Default: `on`
1708
1709**Options**
1710
17111. `on`, enables format on save obeying `formatter` setting:
1712
1713```json [settings]
1714{
1715 "format_on_save": "on"
1716}
1717```
1718
17192. `off`, disables format on save:
1720
1721```json [settings]
1722{
1723 "format_on_save": "off"
1724}
1725```
1726
1727## Formatter
1728
1729- Description: How to perform a buffer format.
1730- Setting: `formatter`
1731- Default: `auto`
1732
1733**Options**
1734
17351. To use the current language server, use `"language_server"`:
1736
1737```json [settings]
1738{
1739 "formatter": "language_server"
1740}
1741```
1742
17432. 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):
1744
1745```json [settings]
1746{
1747 "formatter": {
1748 "external": {
1749 "command": "sed",
1750 "arguments": ["-e", "s/ *$//"]
1751 }
1752 }
1753}
1754```
1755
17563. 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.
1757
1758WARNING: `{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.
1759
1760```json [settings]
1761 "formatter": {
1762 "external": {
1763 "command": "prettier",
1764 "arguments": ["--stdin-filepath", "{buffer_path}"]
1765 }
1766 }
1767```
1768
17694. Or to use code actions provided by the connected language servers, use `"code_actions"`:
1770
1771```json [settings]
1772{
1773 "formatter": [
1774 // Use ESLint's --fix:
1775 { "code_action": "source.fixAll.eslint" },
1776 // Organize imports on save:
1777 { "code_action": "source.organizeImports" }
1778 ]
1779}
1780```
1781
17825. Or to use multiple formatters consecutively, use an array of formatters:
1783
1784```json [settings]
1785{
1786 "formatter": [
1787 { "language_server": { "name": "rust-analyzer" } },
1788 {
1789 "external": {
1790 "command": "sed",
1791 "arguments": ["-e", "s/ *$//"]
1792 }
1793 }
1794 ]
1795}
1796```
1797
1798Here `rust-analyzer` will be used first to format the code, followed by a call of sed.
1799If any of the formatters fails, the subsequent ones will still be executed.
1800
1801## Auto close
1802
1803- Description: Whether to automatically add matching closing characters when typing opening parenthesis, bracket, brace, single or double quote characters.
1804- Setting: `use_autoclose`
1805- Default: `true`
1806
1807**Options**
1808
1809`boolean` values
1810
1811## Always Treat Brackets As Autoclosed
1812
1813- Description: Controls how the editor handles the autoclosed characters.
1814- Setting: `always_treat_brackets_as_autoclosed`
1815- Default: `false`
1816
1817**Options**
1818
1819`boolean` values
1820
1821**Example**
1822
1823If the setting is set to `true`:
1824
18251. Enter in the editor: `)))`
18262. Move the cursor to the start: `^)))`
18273. Enter again: `)))`
1828
1829The result is still `)))` and not `))))))`, which is what it would be by default.
1830
1831## File Scan Exclusions
1832
1833- Setting: `file_scan_exclusions`
1834- 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`.
1835- Default:
1836
1837```json [settings]
1838"file_scan_exclusions": [
1839 "**/.git",
1840 "**/.svn",
1841 "**/.hg",
1842 "**/.jj",
1843 "**/CVS",
1844 "**/.DS_Store",
1845 "**/Thumbs.db",
1846 "**/.classpath",
1847 "**/.settings"
1848],
1849```
1850
1851Note, 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.
1852
1853## File Scan Inclusions
1854
1855- Setting: `file_scan_inclusions`
1856- 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.
1857- Default:
1858
1859```json [settings]
1860"file_scan_inclusions": [".env*"],
1861```
1862
1863## File Types
1864
1865- Setting: `file_types`
1866- Description: Configure how Zed selects a language for a file based on its filename or extension. Supports glob entries.
1867- Default:
1868
1869```json [settings]
1870"file_types": {
1871 "JSONC": ["**/.zed/**/*.json", "**/zed/**/*.json", "**/Zed/**/*.json", "**/.vscode/**/*.json"],
1872 "Shell Script": [".env.*"]
1873}
1874```
1875
1876**Examples**
1877
1878To interpret all `.c` files as C++, files called `MyLockFile` as TOML and files starting with `Dockerfile` as Dockerfile:
1879
1880```json [settings]
1881{
1882 "file_types": {
1883 "C++": ["c"],
1884 "TOML": ["MyLockFile"],
1885 "Dockerfile": ["Dockerfile*"]
1886 }
1887}
1888```
1889
1890## Diagnostics
1891
1892- Description: Configuration for diagnostics-related features.
1893- Setting: `diagnostics`
1894- Default:
1895
1896```json [settings]
1897{
1898 "diagnostics": {
1899 "include_warnings": true,
1900 "inline": {
1901 "enabled": false
1902 },
1903 "update_with_cursor": false,
1904 "primary_only": false,
1905 "use_rendered": false
1906 }
1907}
1908```
1909
1910### Inline Diagnostics
1911
1912- Description: Whether or not to show diagnostics information inline.
1913- Setting: `inline`
1914- Default:
1915
1916```json [settings]
1917{
1918 "diagnostics": {
1919 "inline": {
1920 "enabled": false,
1921 "update_debounce_ms": 150,
1922 "padding": 4,
1923 "min_column": 0,
1924 "max_severity": null
1925 }
1926 }
1927}
1928```
1929
1930**Options**
1931
19321. Enable inline diagnostics.
1933
1934```json [settings]
1935{
1936 "diagnostics": {
1937 "inline": {
1938 "enabled": true
1939 }
1940 }
1941}
1942```
1943
19442. Delay diagnostic updates until some time after the last diagnostic update.
1945
1946```json [settings]
1947{
1948 "diagnostics": {
1949 "inline": {
1950 "enabled": true,
1951 "update_debounce_ms": 150
1952 }
1953 }
1954}
1955```
1956
19573. Set padding between the end of the source line and the start of the diagnostic.
1958
1959```json [settings]
1960{
1961 "diagnostics": {
1962 "inline": {
1963 "enabled": true,
1964 "padding": 4
1965 }
1966 }
1967}
1968```
1969
19704. Horizontally align inline diagnostics at the given column.
1971
1972```json [settings]
1973{
1974 "diagnostics": {
1975 "inline": {
1976 "enabled": true,
1977 "min_column": 80
1978 }
1979 }
1980}
1981```
1982
19835. Show only warning and error diagnostics.
1984
1985```json [settings]
1986{
1987 "diagnostics": {
1988 "inline": {
1989 "enabled": true,
1990 "max_severity": "warning"
1991 }
1992 }
1993}
1994```
1995
1996## Git
1997
1998- Description: Configuration for git-related features.
1999- Setting: `git`
2000- Default:
2001
2002```json [settings]
2003{
2004 "git": {
2005 "git_gutter": "tracked_files",
2006 "inline_blame": {
2007 "enabled": true
2008 },
2009 "branch_picker": {
2010 "show_author_name": true
2011 },
2012 "hunk_style": "staged_hollow"
2013 }
2014}
2015```
2016
2017### Git Gutter
2018
2019- Description: Whether or not to show the git gutter.
2020- Setting: `git_gutter`
2021- Default: `tracked_files`
2022
2023**Options**
2024
20251. Show git gutter in tracked files
2026
2027```json [settings]
2028{
2029 "git": {
2030 "git_gutter": "tracked_files"
2031 }
2032}
2033```
2034
20352. Hide git gutter
2036
2037```json [settings]
2038{
2039 "git": {
2040 "git_gutter": "hide"
2041 }
2042}
2043```
2044
2045### Gutter Debounce
2046
2047- Description: Sets the debounce threshold (in milliseconds) after which changes are reflected in the git gutter.
2048- Setting: `gutter_debounce`
2049- Default: `null`
2050
2051**Options**
2052
2053`integer` values representing milliseconds
2054
2055Example:
2056
2057```json [settings]
2058{
2059 "git": {
2060 "gutter_debounce": 100
2061 }
2062}
2063```
2064
2065### Inline Git Blame
2066
2067- Description: Whether or not to show git blame information inline, on the currently focused line.
2068- Setting: `inline_blame`
2069- Default:
2070
2071```json [settings]
2072{
2073 "git": {
2074 "inline_blame": {
2075 "enabled": true
2076 }
2077 }
2078}
2079```
2080
2081**Options**
2082
20831. Disable inline git blame:
2084
2085```json [settings]
2086{
2087 "git": {
2088 "inline_blame": {
2089 "enabled": false
2090 }
2091 }
2092}
2093```
2094
20952. Only show inline git blame after a delay (that starts after cursor stops moving):
2096
2097```json [settings]
2098{
2099 "git": {
2100 "inline_blame": {
2101 "delay_ms": 500
2102 }
2103 }
2104}
2105```
2106
21073. Show a commit summary next to the commit date and author:
2108
2109```json [settings]
2110{
2111 "git": {
2112 "inline_blame": {
2113 "show_commit_summary": true
2114 }
2115 }
2116}
2117```
2118
21194. Use this as the minimum column at which to display inline blame information:
2120
2121```json [settings]
2122{
2123 "git": {
2124 "inline_blame": {
2125 "min_column": 80
2126 }
2127 }
2128}
2129```
2130
21315. Set the padding between the end of the line and the inline blame hint, in ems:
2132
2133```json [settings]
2134{
2135 "git": {
2136 "inline_blame": {
2137 "padding": 10
2138 }
2139 }
2140}
2141```
2142
2143### Branch Picker
2144
2145- Description: Configuration related to the branch picker.
2146- Setting: `branch_picker`
2147- Default:
2148
2149```json [settings]
2150{
2151 "git": {
2152 "branch_picker": {
2153 "show_author_name": false
2154 }
2155 }
2156}
2157```
2158
2159**Options**
2160
21611. Show the author name in the branch picker:
2162
2163```json [settings]
2164{
2165 "git": {
2166 "branch_picker": {
2167 "show_author_name": true
2168 }
2169 }
2170}
2171```
2172
2173### Hunk Style
2174
2175- Description: What styling we should use for the diff hunks.
2176- Setting: `hunk_style`
2177- Default:
2178
2179```json [settings]
2180{
2181 "git": {
2182 "hunk_style": "staged_hollow"
2183 }
2184}
2185```
2186
2187**Options**
2188
21891. Show the staged hunks faded out and with a border:
2190
2191```json [settings]
2192{
2193 "git": {
2194 "hunk_style": "staged_hollow"
2195 }
2196}
2197```
2198
21992. Show unstaged hunks faded out and with a border:
2200
2201```json [settings]
2202{
2203 "git": {
2204 "hunk_style": "unstaged_hollow"
2205 }
2206}
2207```
2208
2209## Go to Definition Fallback
2210
2211- Description: What to do when the {#action editor::GoToDefinition} action fails to find a definition
2212- Setting: `go_to_definition_fallback`
2213- Default: `"find_all_references"`
2214
2215**Options**
2216
22171. Do nothing:
2218
2219```json [settings]
2220{
2221 "go_to_definition_fallback": "none"
2222}
2223```
2224
22252. Find references for the same symbol (default):
2226
2227```json [settings]
2228{
2229 "go_to_definition_fallback": "find_all_references"
2230}
2231```
2232
2233## Hard Tabs
2234
2235- Description: Whether to indent lines using tab characters or multiple spaces.
2236- Setting: `hard_tabs`
2237- Default: `false`
2238
2239**Options**
2240
2241`boolean` values
2242
2243## Helix Mode
2244
2245- Description: Whether or not to enable Helix mode. Enabling `helix_mode` also enables `vim_mode`. See the [Helix documentation](./helix.md) for more details.
2246- Setting: `helix_mode`
2247- Default: `false`
2248
2249**Options**
2250
2251`boolean` values
2252
2253## Indent Guides
2254
2255- Description: Configuration related to indent guides. Indent guides can be configured separately for each language.
2256- Setting: `indent_guides`
2257- Default:
2258
2259```json [settings]
2260{
2261 "indent_guides": {
2262 "enabled": true,
2263 "line_width": 1,
2264 "active_line_width": 1,
2265 "coloring": "fixed",
2266 "background_coloring": "disabled"
2267 }
2268}
2269```
2270
2271**Options**
2272
22731. Disable indent guides
2274
2275```json [settings]
2276{
2277 "indent_guides": {
2278 "enabled": false
2279 }
2280}
2281```
2282
22832. Enable indent guides for a specific language.
2284
2285```json [settings]
2286{
2287 "languages": {
2288 "Python": {
2289 "indent_guides": {
2290 "enabled": true
2291 }
2292 }
2293 }
2294}
2295```
2296
22973. Enable indent aware coloring ("rainbow indentation").
2298 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.
2299
2300```json [settings]
2301{
2302 "indent_guides": {
2303 "enabled": true,
2304 "coloring": "indent_aware"
2305 }
2306}
2307```
2308
23094. Enable indent aware background coloring ("rainbow indentation").
2310 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.
2311
2312```json [settings]
2313{
2314 "indent_guides": {
2315 "enabled": true,
2316 "coloring": "indent_aware",
2317 "background_coloring": "indent_aware"
2318 }
2319}
2320```
2321
2322## Hover Popover Enabled
2323
2324- Description: Whether or not to show the informational hover box when moving the mouse over symbols in the editor.
2325- Setting: `hover_popover_enabled`
2326- Default: `true`
2327
2328**Options**
2329
2330`boolean` values
2331
2332## Hover Popover Delay
2333
2334- Description: Time to wait in milliseconds before showing the informational hover box.
2335- Setting: `hover_popover_delay`
2336- Default: `300`
2337
2338**Options**
2339
2340`integer` values representing milliseconds
2341
2342## Icon Theme
2343
2344- 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.
2345- Setting: `icon_theme`
2346- Default: `Zed (Default)`
2347
2348### Icon Theme Object
2349
2350- Description: Specify the icon theme using an object that includes the `mode`, `dark`, and `light`.
2351- Setting: `icon_theme`
2352- Default:
2353
2354```json [settings]
2355"icon_theme": {
2356 "mode": "system",
2357 "dark": "Zed (Default)",
2358 "light": "Zed (Default)"
2359},
2360```
2361
2362### Mode
2363
2364- Description: Specify the icon theme mode.
2365- Setting: `mode`
2366- Default: `system`
2367
2368**Options**
2369
23701. Set the icon theme to dark mode
2371
2372```json [settings]
2373{
2374 "mode": "dark"
2375}
2376```
2377
23782. Set the icon theme to light mode
2379
2380```json [settings]
2381{
2382 "mode": "light"
2383}
2384```
2385
23863. Set the icon theme to system mode
2387
2388```json [settings]
2389{
2390 "mode": "system"
2391}
2392```
2393
2394### Dark
2395
2396- Description: The name of the dark icon theme.
2397- Setting: `dark`
2398- Default: `Zed (Default)`
2399
2400**Options**
2401
2402Run the {#action icon_theme_selector::Toggle} action in the command palette to see a current list of valid icon themes names.
2403
2404### Light
2405
2406- Description: The name of the light icon theme.
2407- Setting: `light`
2408- Default: `Zed (Default)`
2409
2410**Options**
2411
2412Run the {#action icon_theme_selector::Toggle} action in the command palette to see a current list of valid icon themes names.
2413
2414## Image Viewer
2415
2416- Description: Settings for image viewer functionality
2417- Setting: `image_viewer`
2418- Default:
2419
2420```json [settings]
2421{
2422 "image_viewer": {
2423 "unit": "binary"
2424 }
2425}
2426```
2427
2428**Options**
2429
2430### Unit
2431
2432- Description: The unit for image file sizes
2433- Setting: `unit`
2434- Default: `"binary"`
2435
2436**Options**
2437
24381. Use binary units (KiB, MiB):
2439
2440```json [settings]
2441{
2442 "image_viewer": {
2443 "unit": "binary"
2444 }
2445}
2446```
2447
24482. Use decimal units (KB, MB):
2449
2450```json [settings]
2451{
2452 "image_viewer": {
2453 "unit": "decimal"
2454 }
2455}
2456```
2457
2458## Inlay hints
2459
2460- Description: Configuration for displaying extra text with hints in the editor.
2461- Setting: `inlay_hints`
2462- Default:
2463
2464```json [settings]
2465"inlay_hints": {
2466 "enabled": false,
2467 "show_type_hints": true,
2468 "show_parameter_hints": true,
2469 "show_other_hints": true,
2470 "show_background": false,
2471 "edit_debounce_ms": 700,
2472 "scroll_debounce_ms": 50,
2473 "toggle_on_modifiers_press": null
2474}
2475```
2476
2477**Options**
2478
2479Inlay hints querying consists of two parts: editor (client) and LSP server.
2480With 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.
2481At 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.
2482
2483The following languages have inlay hints preconfigured by Zed:
2484
2485- [Go](https://docs.zed.dev/languages/go)
2486- [Rust](https://docs.zed.dev/languages/rust)
2487- [Svelte](https://docs.zed.dev/languages/svelte)
2488- [TypeScript](https://docs.zed.dev/languages/typescript)
2489
2490Use the `lsp` section for the server configuration. Examples are provided in the corresponding language documentation.
2491
2492Hints are not instantly queried in Zed, two kinds of debounces are used, either may be set to 0 to be disabled.
2493Settings-related hint updates are not debounced.
2494
2495All possible config values for `toggle_on_modifiers_press` are:
2496
2497```json [settings]
2498"inlay_hints": {
2499 "toggle_on_modifiers_press": {
2500 "control": true,
2501 "shift": true,
2502 "alt": true,
2503 "platform": true,
2504 "function": true
2505 }
2506}
2507```
2508
2509Unspecified values have a `false` value, hints won't be toggled if all the modifiers are `false` or not all the modifiers are pressed.
2510
2511## Journal
2512
2513- Description: Configuration for the journal.
2514- Setting: `journal`
2515- Default:
2516
2517```json [settings]
2518"journal": {
2519 "path": "~",
2520 "hour_format": "hour12"
2521}
2522
2523```
2524
2525### Path
2526
2527- Description: The path of the directory where journal entries are stored. If an invalid path is specified, the journal will fall back to using `~` (the home directory).
2528- Setting: `path`
2529- Default: `~`
2530
2531**Options**
2532
2533`string` values
2534
2535### Hour Format
2536
2537- Description: The format to use for displaying hours in the journal.
2538- Setting: `hour_format`
2539- Default: `hour12`
2540
2541**Options**
2542
25431. 12-hour format:
2544
2545```json [settings]
2546{
2547 "hour_format": "hour12"
2548}
2549```
2550
25512. 24-hour format:
2552
2553```json [settings]
2554{
2555 "hour_format": "hour24"
2556}
2557```
2558
2559## JSX Tag Auto Close
2560
2561- Description: Whether to automatically close JSX tags
2562- Setting: `jsx_tag_auto_close`
2563- Default:
2564
2565```json [settings]
2566{
2567 "jsx_tag_auto_close": {
2568 "enabled": true
2569 }
2570}
2571```
2572
2573**Options**
2574
2575- `enabled`: Whether to enable automatic JSX tag closing
2576
2577## Languages
2578
2579- Description: Configuration for specific languages.
2580- Setting: `languages`
2581- Default: `null`
2582
2583**Options**
2584
2585To override settings for a language, add an entry for that languages name to the `languages` value. Example:
2586
2587```json [settings]
2588"languages": {
2589 "C": {
2590 "format_on_save": "off",
2591 "preferred_line_length": 64,
2592 "soft_wrap": "preferred_line_length"
2593 },
2594 "JSON": {
2595 "tab_size": 4
2596 }
2597}
2598```
2599
2600The following settings can be overridden for each specific language:
2601
2602- [`enable_language_server`](#enable-language-server)
2603- [`ensure_final_newline_on_save`](#ensure-final-newline-on-save)
2604- [`format_on_save`](#format-on-save)
2605- [`formatter`](#formatter)
2606- [`hard_tabs`](#hard-tabs)
2607- [`preferred_line_length`](#preferred-line-length)
2608- [`remove_trailing_whitespace_on_save`](#remove-trailing-whitespace-on-save)
2609- [`show_edit_predictions`](#show-edit-predictions)
2610- [`show_whitespaces`](#show-whitespaces)
2611- [`whitespace_map`](#whitespace-map)
2612- [`soft_wrap`](#soft-wrap)
2613- [`tab_size`](#tab-size)
2614- [`use_autoclose`](#use-autoclose)
2615- [`always_treat_brackets_as_autoclosed`](#always-treat-brackets-as-autoclosed)
2616
2617These values take in the same options as the root-level settings with the same name.
2618
2619## Language Models
2620
2621- Description: Configuration for language model providers
2622- Setting: `language_models`
2623- Default:
2624
2625```json [settings]
2626{
2627 "language_models": {
2628 "anthropic": {
2629 "api_url": "https://api.anthropic.com"
2630 },
2631 "google": {
2632 "api_url": "https://generativelanguage.googleapis.com"
2633 },
2634 "ollama": {
2635 "api_url": "http://localhost:11434"
2636 },
2637 "openai": {
2638 "api_url": "https://api.openai.com/v1"
2639 }
2640 }
2641}
2642```
2643
2644**Options**
2645
2646Configuration for various AI model providers including API URLs and authentication settings.
2647
2648## Line Indicator Format
2649
2650- Description: Format for line indicator in the status bar
2651- Setting: `line_indicator_format`
2652- Default: `"short"`
2653
2654**Options**
2655
26561. Short format:
2657
2658```json [settings]
2659{
2660 "line_indicator_format": "short"
2661}
2662```
2663
26642. Long format:
2665
2666```json [settings]
2667{
2668 "line_indicator_format": "long"
2669}
2670```
2671
2672## Linked Edits
2673
2674- 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.
2675- Setting: `linked_edits`
2676- Default: `true`
2677
2678**Options**
2679
2680`boolean` values
2681
2682## LSP Document Colors
2683
2684- Description: Whether to show document color information from the language server
2685- Setting: `lsp_document_colors`
2686- Default: `true`
2687
2688**Options**
2689
2690`boolean` values
2691
2692## Max Tabs
2693
2694- Description: Maximum number of tabs to show in the tab bar
2695- Setting: `max_tabs`
2696- Default: `null`
2697
2698**Options**
2699
2700Positive `integer` values or `null` for unlimited tabs
2701
2702## Middle Click Paste (Linux only)
2703
2704- Description: Enable middle-click paste on Linux
2705- Setting: `middle_click_paste`
2706- Default: `true`
2707
2708**Options**
2709
2710`boolean` values
2711
2712## Multi Cursor Modifier
2713
2714- 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.
2715- Setting: `multi_cursor_modifier`
2716- Default: `alt`
2717
2718**Options**
2719
27201. Maps to `Alt` on Linux and Windows and to `Option` on macOS:
2721
2722```json [settings]
2723{
2724 "multi_cursor_modifier": "alt"
2725}
2726```
2727
27282. Maps `Control` on Linux and Windows and to `Command` on macOS:
2729
2730```json [settings]
2731{
2732 "multi_cursor_modifier": "cmd_or_ctrl" // alias: "cmd", "ctrl"
2733}
2734```
2735
2736## Node
2737
2738- Description: Configuration for Node.js integration
2739- Setting: `node`
2740- Default:
2741
2742```json [settings]
2743{
2744 "node": {
2745 "ignore_system_version": false,
2746 "path": null,
2747 "npm_path": null
2748 }
2749}
2750```
2751
2752**Options**
2753
2754- `ignore_system_version`: Whether to ignore the system Node.js version
2755- `path`: Custom path to Node.js binary
2756- `npm_path`: Custom path to npm binary
2757
2758## Network Proxy
2759
2760- Description: Configure a network proxy for Zed.
2761- Setting: `proxy`
2762- Default: `null`
2763
2764**Options**
2765
2766The proxy setting must contain a URL to the proxy.
2767
2768The following URI schemes are supported:
2769
2770- `http`
2771- `https`
2772- `socks4` - SOCKS4 proxy with local DNS
2773- `socks4a` - SOCKS4 proxy with remote DNS
2774- `socks5` - SOCKS5 proxy with local DNS
2775- `socks5h` - SOCKS5 proxy with remote DNS
2776
2777`http` will be used when no scheme is specified.
2778
2779By 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`.
2780
2781For example, to set an `http` proxy, add the following to your settings:
2782
2783```json [settings]
2784{
2785 "proxy": "http://127.0.0.1:10809"
2786}
2787```
2788
2789Or to set a `socks5` proxy:
2790
2791```json [settings]
2792{
2793 "proxy": "socks5h://localhost:10808"
2794}
2795```
2796
2797If 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.
2798
2799## On Last Window Closed
2800
2801- Description: What to do when the last window is closed
2802- Setting: `on_last_window_closed`
2803- Default: `"platform_default"`
2804
2805**Options**
2806
28071. Use platform default behavior:
2808
2809```json [settings]
2810{
2811 "on_last_window_closed": "platform_default"
2812}
2813```
2814
28152. Always quit the application:
2816
2817```json [settings]
2818{
2819 "on_last_window_closed": "quit_app"
2820}
2821```
2822
2823## Profiles
2824
2825- Description: Configuration profiles that can be applied on top of existing settings
2826- Setting: `profiles`
2827- Default: `{}`
2828
2829**Options**
2830
2831Configuration object for defining settings profiles. Example:
2832
2833```json [settings]
2834{
2835 "profiles": {
2836 "presentation": {
2837 "buffer_font_size": 20,
2838 "ui_font_size": 18,
2839 "theme": "One Light"
2840 }
2841 }
2842}
2843```
2844
2845## Preview tabs
2846
2847- Description:
2848 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. \
2849 There are several ways to convert a preview tab into a regular tab:
2850
2851 - Double-clicking on the file
2852 - Double-clicking on the tab header
2853 - Using the {#action project_panel::OpenPermanent} action
2854 - Editing the file
2855 - Dragging the file to a different pane
2856
2857- Setting: `preview_tabs`
2858- Default:
2859
2860```json [settings]
2861"preview_tabs": {
2862 "enabled": true,
2863 "enable_preview_from_file_finder": false,
2864 "enable_preview_from_code_navigation": false,
2865}
2866```
2867
2868### Enable preview from file finder
2869
2870- Description: Determines whether to open files in preview mode when selected from the file finder.
2871- Setting: `enable_preview_from_file_finder`
2872- Default: `false`
2873
2874**Options**
2875
2876`boolean` values
2877
2878### Enable preview from code navigation
2879
2880- Description: Determines whether a preview tab gets replaced when code navigation is used to navigate away from the tab.
2881- Setting: `enable_preview_from_code_navigation`
2882- Default: `false`
2883
2884**Options**
2885
2886`boolean` values
2887
2888## File Finder
2889
2890### File Icons
2891
2892- Description: Whether to show file icons in the file finder.
2893- Setting: `file_icons`
2894- Default: `true`
2895
2896### Modal Max Width
2897
2898- Description: Max-width of the file finder modal. It can take one of these values: `small`, `medium`, `large`, `xlarge`, and `full`.
2899- Setting: `modal_max_width`
2900- Default: `small`
2901
2902### Skip Focus For Active In Search
2903
2904- Description: Determines whether the file finder should skip focus for the active file in search results.
2905- Setting: `skip_focus_for_active_in_search`
2906- Default: `true`
2907
2908## Pane Split Direction Horizontal
2909
2910- Description: The direction that you want to split panes horizontally
2911- Setting: `pane_split_direction_horizontal`
2912- Default: `"up"`
2913
2914**Options**
2915
29161. Split upward:
2917
2918```json [settings]
2919{
2920 "pane_split_direction_horizontal": "up"
2921}
2922```
2923
29242. Split downward:
2925
2926```json [settings]
2927{
2928 "pane_split_direction_horizontal": "down"
2929}
2930```
2931
2932## Pane Split Direction Vertical
2933
2934- Description: The direction that you want to split panes vertically
2935- Setting: `pane_split_direction_vertical`
2936- Default: `"left"`
2937
2938**Options**
2939
29401. Split to the left:
2941
2942```json [settings]
2943{
2944 "pane_split_direction_vertical": "left"
2945}
2946```
2947
29482. Split to the right:
2949
2950```json [settings]
2951{
2952 "pane_split_direction_vertical": "right"
2953}
2954```
2955
2956## Preferred Line Length
2957
2958- Description: The column at which to soft-wrap lines, for buffers where soft-wrap is enabled.
2959- Setting: `preferred_line_length`
2960- Default: `80`
2961
2962**Options**
2963
2964`integer` values
2965
2966## Private Files
2967
2968- Description: Globs to match against file paths to determine if a file is private
2969- Setting: `private_files`
2970- Default: `["**/.env*", "**/*.pem", "**/*.key", "**/*.cert", "**/*.crt", "**/secrets.yml"]`
2971
2972**Options**
2973
2974List of `string` glob patterns
2975
2976## Projects Online By Default
2977
2978- Description: Whether or not to show the online projects view by default.
2979- Setting: `projects_online_by_default`
2980- Default: `true`
2981
2982**Options**
2983
2984`boolean` values
2985
2986## Read SSH Config
2987
2988- Description: Whether to read SSH configuration files
2989- Setting: `read_ssh_config`
2990- Default: `true`
2991
2992**Options**
2993
2994`boolean` values
2995
2996## Redact Private Values
2997
2998- Description: Hide the values of variables from visual display in private files
2999- Setting: `redact_private_values`
3000- Default: `false`
3001
3002**Options**
3003
3004`boolean` values
3005
3006## Relative Line Numbers
3007
3008- Description: Whether to show relative line numbers in the gutter
3009- Setting: `relative_line_numbers`
3010- Default: `"disabled"`
3011
3012**Options**
3013
30141. Show relative line numbers in the gutter whilst counting wrapped lines as one line:
3015
3016```json [settings]
3017{
3018 "relative_line_numbers": "enabled"
3019}
3020```
3021
30222. Show relative line numbers in the gutter, including wrapped lines in the counting:
3023
3024```json [settings]
3025{
3026 "relative_line_numbers": "wrapped"
3027}
3028```
3029
30302. Do not use relative line numbers:
3031
3032```json [settings]
3033{
3034 "relative_line_numbers": "disabled"
3035}
3036```
3037
3038## Remove Trailing Whitespace On Save
3039
3040- Description: Whether or not to remove any trailing whitespace from lines of a buffer before saving it.
3041- Setting: `remove_trailing_whitespace_on_save`
3042- Default: `true`
3043
3044**Options**
3045
3046`boolean` values
3047
3048## Resize All Panels In Dock
3049
3050- Description: Whether to resize all the panels in a dock when resizing the dock. Can be a combination of "left", "right" and "bottom".
3051- Setting: `resize_all_panels_in_dock`
3052- Default: `["left"]`
3053
3054**Options**
3055
3056List of strings containing any combination of:
3057
3058- `"left"`: Resize left dock panels together
3059- `"right"`: Resize right dock panels together
3060- `"bottom"`: Resize bottom dock panels together
3061
3062## Restore on File Reopen
3063
3064- Description: Whether to attempt to restore previous file's state when opening it again. The state is stored per pane.
3065- Setting: `restore_on_file_reopen`
3066- Default: `true`
3067
3068**Options**
3069
3070`boolean` values
3071
3072## Restore on Startup
3073
3074- Description: Controls session restoration on startup.
3075- Setting: `restore_on_startup`
3076- Default: `last_session`
3077
3078**Options**
3079
30801. Restore all workspaces that were open when quitting Zed:
3081
3082```json [settings]
3083{
3084 "restore_on_startup": "last_session"
3085}
3086```
3087
30882. Restore the workspace that was closed last:
3089
3090```json [settings]
3091{
3092 "restore_on_startup": "last_workspace"
3093}
3094```
3095
30963. Always start with an empty editor:
3097
3098```json [settings]
3099{
3100 "restore_on_startup": "none"
3101}
3102```
3103
3104## Scroll Beyond Last Line
3105
3106- Description: Whether the editor will scroll beyond the last line
3107- Setting: `scroll_beyond_last_line`
3108- Default: `"one_page"`
3109
3110**Options**
3111
31121. Scroll one page beyond the last line by one page:
3113
3114```json [settings]
3115{
3116 "scroll_beyond_last_line": "one_page"
3117}
3118```
3119
31202. The editor will scroll beyond the last line by the same amount of lines as `vertical_scroll_margin`:
3121
3122```json [settings]
3123{
3124 "scroll_beyond_last_line": "vertical_scroll_margin"
3125}
3126```
3127
31283. The editor will not scroll beyond the last line:
3129
3130```json [settings]
3131{
3132 "scroll_beyond_last_line": "off"
3133}
3134```
3135
3136**Options**
3137
3138`boolean` values
3139
3140## Scroll Sensitivity
3141
3142- Description: Scroll sensitivity multiplier. This multiplier is applied to both the horizontal and vertical delta values while scrolling.
3143- Setting: `scroll_sensitivity`
3144- Default: `1.0`
3145
3146**Options**
3147
3148Positive `float` values
3149
3150### Fast Scroll Sensitivity
3151
3152- 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.
3153- Setting: `fast_scroll_sensitivity`
3154- Default: `4.0`
3155
3156**Options**
3157
3158Positive `float` values
3159
3160### Horizontal Scroll Margin
3161
3162- Description: The number of characters to keep on either side when scrolling with the mouse
3163- Setting: `horizontal_scroll_margin`
3164- Default: `5`
3165
3166**Options**
3167
3168Non-negative `integer` values
3169
3170### Vertical Scroll Margin
3171
3172- Description: The number of lines to keep above/below the cursor when scrolling with the keyboard
3173- Setting: `vertical_scroll_margin`
3174- Default: `3`
3175
3176**Options**
3177
3178Non-negative `integer` values
3179
3180## Search
3181
3182- Description: Search options to enable by default when opening new project and buffer searches.
3183- Setting: `search`
3184- Default:
3185
3186```json [settings]
3187"search": {
3188 "button": true,
3189 "whole_word": false,
3190 "case_sensitive": false,
3191 "include_ignored": false,
3192 "regex": false,
3193 "center_on_match": false
3194},
3195```
3196
3197### Button
3198
3199- Description: Whether to show the project search button in the status bar.
3200- Setting: `button`
3201- Default: `true`
3202
3203### Whole Word
3204
3205- Description: Whether to only match on whole words.
3206- Setting: `whole_word`
3207- Default: `false`
3208
3209### Case Sensitive
3210
3211- Description: Whether to match case sensitively. This setting affects both
3212 searches and editor actions like "Select Next Occurrence", "Select Previous
3213 Occurrence", and "Select All Occurrences".
3214- Setting: `case_sensitive`
3215- Default: `false`
3216
3217### Include Ignore
3218
3219- Description: Whether to include gitignored files in search results.
3220- Setting: `include_ignored`
3221- Default: `false`
3222
3223### Regex
3224
3225- Description: Whether to interpret the search query as a regular expression.
3226- Setting: `regex`
3227- Default: `false`
3228
3229### Center On Match
3230
3231- Description: Whether to center the cursor on each search match when navigating.
3232- Setting: `center_on_match`
3233- Default: `false`
3234
3235## Search Wrap
3236
3237- Description: If `search_wrap` is disabled, search result do not wrap around the end of the file
3238- Setting: `search_wrap`
3239- Default: `true`
3240
3241## Center on Match
3242
3243- Description: If `center_on_match` is enabled, the editor will center the cursor on the current match when searching.
3244- Setting: `center_on_match`
3245- Default: `false`
3246
3247## Seed Search Query From Cursor
3248
3249- Description: When to populate a new search's query based on the text under the cursor.
3250- Setting: `seed_search_query_from_cursor`
3251- Default: `always`
3252
3253**Options**
3254
32551. `always` always populate the search query with the word under the cursor
32562. `selection` only populate the search query when there is text selected
32573. `never` never populate the search query
3258
3259## Use Smartcase Search
3260
3261- 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. \
3262 This applies to both in-file searches and project-wide searches.
3263- Setting: `use_smartcase_search`
3264- Default: `false`
3265
3266**Options**
3267
3268`boolean` values
3269
3270Examples:
3271
3272- Searching for "function" would match "function", "Function", "FUNCTION", etc.
3273- Searching for "Function" would only match "Function", not "function" or "FUNCTION"
3274
3275## Show Call Status Icon
3276
3277- Description: Whether or not to show the call status icon in the status bar.
3278- Setting: `show_call_status_icon`
3279- Default: `true`
3280
3281**Options**
3282
3283`boolean` values
3284
3285## Completions
3286
3287- Description: Controls how completions are processed for this language.
3288- Setting: `completions`
3289- Default:
3290
3291```json [settings]
3292{
3293 "completions": {
3294 "words": "fallback",
3295 "words_min_length": 3,
3296 "lsp": true,
3297 "lsp_fetch_timeout_ms": 0,
3298 "lsp_insert_mode": "replace_suffix"
3299 }
3300}
3301```
3302
3303### Words
3304
3305- Description: Controls how words are completed. For large documents, not all words may be fetched for completion.
3306- Setting: `words`
3307- Default: `fallback`
3308
3309**Options**
3310
33111. `enabled` - Always fetch document's words for completions along with LSP completions
33122. `fallback` - Only if LSP response errors or times out, use document's words to show completions
33133. `disabled` - Never fetch or complete document's words for completions (word-based completions can still be queried via a separate action)
3314
3315### Min Words Query Length
3316
3317- Description: Minimum number of characters required to automatically trigger word-based completions.
3318 Before that value, it's still possible to trigger the words-based completion manually with the corresponding editor command.
3319- Setting: `words_min_length`
3320- Default: `3`
3321
3322**Options**
3323
3324Positive integer values
3325
3326### LSP
3327
3328- Description: Whether to fetch LSP completions or not.
3329- Setting: `lsp`
3330- Default: `true`
3331
3332**Options**
3333
3334`boolean` values
3335
3336### LSP Fetch Timeout (ms)
3337
3338- Description: When fetching LSP completions, determines how long to wait for a response of a particular server. When set to 0, waits indefinitely.
3339- Setting: `lsp_fetch_timeout_ms`
3340- Default: `0`
3341
3342**Options**
3343
3344`integer` values representing milliseconds
3345
3346### LSP Insert Mode
3347
3348- Description: Controls what range to replace when accepting LSP completions.
3349- Setting: `lsp_insert_mode`
3350- Default: `replace_suffix`
3351
3352**Options**
3353
33541. `insert` - Replaces text before the cursor, using the `insert` range described in the LSP specification
33552. `replace` - Replaces text before and after the cursor, using the `replace` range described in the LSP specification
33563. `replace_subsequence` - Behaves like `"replace"` if the text that would be replaced is a subsequence of the completion text, and like `"insert"` otherwise
33574. `replace_suffix` - Behaves like `"replace"` if the text after the cursor is a suffix of the completion, and like `"insert"` otherwise
3358
3359## Show Completions On Input
3360
3361- Description: Whether or not to show completions as you type.
3362- Setting: `show_completions_on_input`
3363- Default: `true`
3364
3365**Options**
3366
3367`boolean` values
3368
3369## Show Completion Documentation
3370
3371- Description: Whether to display inline and alongside documentation for items in the completions menu.
3372- Setting: `show_completion_documentation`
3373- Default: `true`
3374
3375**Options**
3376
3377`boolean` values
3378
3379## Show Edit Predictions
3380
3381- Description: Whether to show edit predictions as you type or manually by triggering `editor::ShowEditPrediction`.
3382- Setting: `show_edit_predictions`
3383- Default: `true`
3384
3385**Options**
3386
3387`boolean` values
3388
3389## Show Whitespaces
3390
3391- Description: Whether or not to render whitespace characters in the editor.
3392- Setting: `show_whitespaces`
3393- Default: `selection`
3394
3395**Options**
3396
33971. `all`
33982. `selection`
33993. `none`
34004. `boundary`
3401
3402## Whitespace Map
3403
3404- Description: Specify the characters used to render whitespace when show_whitespaces is enabled.
3405- Setting: `whitespace_map`
3406- Default:
3407
3408```json [settings]
3409{
3410 "whitespace_map": {
3411 "space": "•",
3412 "tab": "→"
3413 }
3414}
3415```
3416
3417## Soft Wrap
3418
3419- Description: Whether or not to automatically wrap lines of text to fit editor / preferred width.
3420- Setting: `soft_wrap`
3421- Default: `none`
3422
3423**Options**
3424
34251. `none` to avoid wrapping generally, unless the line is too long
34262. `prefer_line` (deprecated, same as `none`)
34273. `editor_width` to wrap lines that overflow the editor width
34284. `preferred_line_length` to wrap lines that overflow `preferred_line_length` config value
34295. `bounded` to wrap lines at the minimum of `editor_width` and `preferred_line_length`
3430
3431## Show Wrap Guides
3432
3433- 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.
3434- Setting: `show_wrap_guides`
3435- Default: `true`
3436
3437**Options**
3438
3439`boolean` values
3440
3441## Use On Type Format
3442
3443- Description: Whether to use additional LSP queries to format (and amend) the code after every "trigger" symbol input, defined by LSP server capabilities
3444- Setting: `use_on_type_format`
3445- Default: `true`
3446
3447**Options**
3448
3449`boolean` values
3450
3451## Use Auto Surround
3452
3453- 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 ().
3454- Setting: `use_auto_surround`
3455- Default: `true`
3456
3457**Options**
3458
3459`boolean` values
3460
3461## Use System Path Prompts
3462
3463- 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.
3464- Setting: `use_system_path_prompts`
3465- Default: `true`
3466
3467**Options**
3468
3469`boolean` values
3470
3471## Use System Prompts
3472
3473- 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.
3474- Setting: `use_system_prompts`
3475- Default: `true`
3476
3477**Options**
3478
3479`boolean` values
3480
3481## Wrap Guides (Vertical Rulers)
3482
3483- Description: Where to display vertical rulers as wrap-guides. Disable by setting `show_wrap_guides` to `false`.
3484- Setting: `wrap_guides`
3485- Default: []
3486
3487**Options**
3488
3489List of `integer` column numbers
3490
3491## Tab Size
3492
3493- Description: The number of spaces to use for each tab character.
3494- Setting: `tab_size`
3495- Default: `4`
3496
3497**Options**
3498
3499`integer` values
3500
3501## Tasks
3502
3503- Description: Configuration for tasks that can be run within Zed
3504- Setting: `tasks`
3505- Default:
3506
3507```json [settings]
3508{
3509 "tasks": {
3510 "variables": {},
3511 "enabled": true,
3512 "prefer_lsp": false
3513 }
3514}
3515```
3516
3517**Options**
3518
3519- `variables`: Custom variables for task configuration
3520- `enabled`: Whether tasks are enabled
3521- `prefer_lsp`: Whether to prefer LSP-provided tasks over Zed language extension ones
3522
3523## Telemetry
3524
3525- Description: Control what info is collected by Zed.
3526- Setting: `telemetry`
3527- Default:
3528
3529```json [settings]
3530"telemetry": {
3531 "diagnostics": true,
3532 "metrics": true
3533},
3534```
3535
3536**Options**
3537
3538### Diagnostics
3539
3540- Description: Setting for sending debug-related data, such as crash reports.
3541- Setting: `diagnostics`
3542- Default: `true`
3543
3544**Options**
3545
3546`boolean` values
3547
3548### Metrics
3549
3550- Description: Setting for sending anonymized usage data, such what languages you're using Zed with.
3551- Setting: `metrics`
3552- Default: `true`
3553
3554**Options**
3555
3556`boolean` values
3557
3558## Terminal
3559
3560- Description: Configuration for the terminal.
3561- Setting: `terminal`
3562- Default:
3563
3564```json [settings]
3565{
3566 "terminal": {
3567 "alternate_scroll": "off",
3568 "blinking": "terminal_controlled",
3569 "copy_on_select": false,
3570 "keep_selection_on_copy": true,
3571 "dock": "bottom",
3572 "default_width": 640,
3573 "default_height": 320,
3574 "detect_venv": {
3575 "on": {
3576 "directories": [".env", "env", ".venv", "venv"],
3577 "activate_script": "default"
3578 }
3579 },
3580 "env": {},
3581 "font_family": null,
3582 "font_features": null,
3583 "font_size": null,
3584 "line_height": "comfortable",
3585 "minimum_contrast": 45,
3586 "option_as_meta": false,
3587 "button": true,
3588 "shell": "system",
3589 "scroll_multiplier": 3.0,
3590 "toolbar": {
3591 "breadcrumbs": false
3592 },
3593 "working_directory": "current_project_directory",
3594 "scrollbar": {
3595 "show": null
3596 }
3597 }
3598}
3599```
3600
3601### Terminal: Dock
3602
3603- Description: Control the position of the dock
3604- Setting: `dock`
3605- Default: `bottom`
3606
3607**Options**
3608
3609`"bottom"`, `"left"` or `"right"`
3610
3611### Terminal: Alternate Scroll
3612
3613- 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.
3614- Setting: `alternate_scroll`
3615- Default: `off`
3616
3617**Options**
3618
36191. Default alternate scroll mode to off
3620
3621```json [settings]
3622{
3623 "terminal": {
3624 "alternate_scroll": "off"
3625 }
3626}
3627```
3628
36292. Default alternate scroll mode to on
3630
3631```json [settings]
3632{
3633 "terminal": {
3634 "alternate_scroll": "on"
3635 }
3636}
3637```
3638
3639### Terminal: Blinking
3640
3641- Description: Set the cursor blinking behavior in the terminal
3642- Setting: `blinking`
3643- Default: `terminal_controlled`
3644
3645**Options**
3646
36471. Never blink the cursor, ignore the terminal mode
3648
3649```json [settings]
3650{
3651 "terminal": {
3652 "blinking": "off"
3653 }
3654}
3655```
3656
36572. Default the cursor blink to off, but allow the terminal to turn blinking on
3658
3659```json [settings]
3660{
3661 "terminal": {
3662 "blinking": "terminal_controlled"
3663 }
3664}
3665```
3666
36673. Always blink the cursor, ignore the terminal mode
3668
3669```json [settings]
3670{
3671 "terminal": {
3672 "blinking": "on"
3673 }
3674}
3675```
3676
3677### Terminal: Copy On Select
3678
3679- Description: Whether or not selecting text in the terminal will automatically copy to the system clipboard.
3680- Setting: `copy_on_select`
3681- Default: `false`
3682
3683**Options**
3684
3685`boolean` values
3686
3687**Example**
3688
3689```json [settings]
3690{
3691 "terminal": {
3692 "copy_on_select": true
3693 }
3694}
3695```
3696
3697### Terminal: Cursor Shape
3698
3699- Description: Controls the visual shape of the cursor in the terminal. When not explicitly set, it defaults to a block shape.
3700- Setting: `cursor_shape`
3701- Default: `null` (defaults to block)
3702
3703**Options**
3704
37051. A block that surrounds the following character
3706
3707```json [settings]
3708{
3709 "terminal": {
3710 "cursor_shape": "block"
3711 }
3712}
3713```
3714
37152. A vertical bar
3716
3717```json [settings]
3718{
3719 "terminal": {
3720 "cursor_shape": "bar"
3721 }
3722}
3723```
3724
37253. An underline / underscore that runs along the following character
3726
3727```json [settings]
3728{
3729 "terminal": {
3730 "cursor_shape": "underline"
3731 }
3732}
3733```
3734
37354. A box drawn around the following character
3736
3737```json [settings]
3738{
3739 "terminal": {
3740 "cursor_shape": "hollow"
3741 }
3742}
3743```
3744
3745### Terminal: Keep Selection On Copy
3746
3747- Description: Whether or not to keep the selection in the terminal after copying text.
3748- Setting: `keep_selection_on_copy`
3749- Default: `true`
3750
3751**Options**
3752
3753`boolean` values
3754
3755**Example**
3756
3757```json [settings]
3758{
3759 "terminal": {
3760 "keep_selection_on_copy": false
3761 }
3762}
3763```
3764
3765### Terminal: Env
3766
3767- 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
3768- Setting: `env`
3769- Default: `{}`
3770
3771**Example**
3772
3773```json [settings]
3774{
3775 "terminal": {
3776 "env": {
3777 "ZED": "1",
3778 "KEY": "value1:value2"
3779 }
3780 }
3781}
3782```
3783
3784### Terminal: Font Size
3785
3786- Description: What font size to use for the terminal. When not set defaults to matching the editor's font size
3787- Setting: `font_size`
3788- Default: `null`
3789
3790**Options**
3791
3792`integer` values
3793
3794```json [settings]
3795{
3796 "terminal": {
3797 "font_size": 15
3798 }
3799}
3800```
3801
3802### Terminal: Font Family
3803
3804- Description: What font to use for the terminal. When not set, defaults to matching the editor's font.
3805- Setting: `font_family`
3806- Default: `null`
3807
3808**Options**
3809
3810The name of any font family installed on the user's system
3811
3812```json [settings]
3813{
3814 "terminal": {
3815 "font_family": "Berkeley Mono"
3816 }
3817}
3818```
3819
3820### Terminal: Font Features
3821
3822- Description: What font features to use for the terminal. When not set, defaults to matching the editor's font features.
3823- Setting: `font_features`
3824- Default: `null`
3825- Platform: macOS and Windows.
3826
3827**Options**
3828
3829See Buffer Font Features
3830
3831```json [settings]
3832{
3833 "terminal": {
3834 "font_features": {
3835 "calt": false
3836 // See Buffer Font Features for more features
3837 }
3838 }
3839}
3840```
3841
3842### Terminal: Line Height
3843
3844- Description: Set the terminal's line height.
3845- Setting: `line_height`
3846- Default: `standard`
3847
3848**Options**
3849
38501. Use a line height that's `comfortable` for reading, 1.618.
3851
3852```json [settings]
3853{
3854 "terminal": {
3855 "line_height": "comfortable"
3856 }
3857}
3858```
3859
38602. Use a `standard` line height, 1.3. This option is useful for TUIs, particularly if they use box characters. (default)
3861
3862```json [settings]
3863{
3864 "terminal": {
3865 "line_height": "standard"
3866 }
3867}
3868```
3869
38703. Use a custom line height.
3871
3872```json [settings]
3873{
3874 "terminal": {
3875 "line_height": {
3876 "custom": 2
3877 }
3878 }
3879}
3880```
3881
3882### Terminal: Minimum Contrast
3883
3884- 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.
3885- Setting: `minimum_contrast`
3886- Default: `45`
3887
3888**Options**
3889
3890`integer` values from 0 to 106. Common recommended values:
3891
3892- `0`: No contrast adjustment
3893- `45`: Minimum for large fluent text (default)
3894- `60`: Minimum for other content text
3895- `75`: Minimum for body text
3896- `90`: Preferred for body text
3897
3898```json [settings]
3899{
3900 "terminal": {
3901 "minimum_contrast": 45
3902 }
3903}
3904```
3905
3906### Terminal: Option As Meta
3907
3908- Description: Re-interprets the option keys to act like a 'meta' key, like in Emacs.
3909- Setting: `option_as_meta`
3910- Default: `false`
3911
3912**Options**
3913
3914`boolean` values
3915
3916```json [settings]
3917{
3918 "terminal": {
3919 "option_as_meta": true
3920 }
3921}
3922```
3923
3924### Terminal: Shell
3925
3926- Description: What shell to use when launching the terminal.
3927- Setting: `shell`
3928- Default: `system`
3929
3930**Options**
3931
39321. Use the system's default terminal configuration (usually the `/etc/passwd` file).
3933
3934```json [settings]
3935{
3936 "terminal": {
3937 "shell": "system"
3938 }
3939}
3940```
3941
39422. A program to launch:
3943
3944```json [settings]
3945{
3946 "terminal": {
3947 "shell": {
3948 "program": "sh"
3949 }
3950 }
3951}
3952```
3953
39543. A program with arguments:
3955
3956```json [settings]
3957{
3958 "terminal": {
3959 "shell": {
3960 "with_arguments": {
3961 "program": "/bin/bash",
3962 "args": ["--login"]
3963 }
3964 }
3965 }
3966}
3967```
3968
3969## Terminal: Detect Virtual Environments {#terminal-detect_venv}
3970
3971- 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.
3972- Setting: `detect_venv`
3973- Default:
3974
3975```json [settings]
3976{
3977 "terminal": {
3978 "detect_venv": {
3979 "on": {
3980 // Default directories to search for virtual environments, relative
3981 // to the current working directory. We recommend overriding this
3982 // in your project's settings, rather than globally.
3983 "directories": [".env", "env", ".venv", "venv"],
3984 // Can also be `csh`, `fish`, and `nushell`
3985 "activate_script": "default"
3986 }
3987 }
3988 }
3989}
3990```
3991
3992Disable with:
3993
3994```json [settings]
3995{
3996 "terminal": {
3997 "detect_venv": "off"
3998 }
3999}
4000```
4001
4002### Terminal: Scroll Multiplier
4003
4004- Description: The multiplier for scrolling speed in the terminal when using mouse wheel or trackpad.
4005- Setting: `scroll_multiplier`
4006- Default: `1.0`
4007
4008**Options**
4009
4010Positive floating point values. Values less than or equal to 0 will be clamped to a minimum of 0.01.
4011
4012**Example**
4013
4014```json
4015{
4016 "terminal": {
4017 "scroll_multiplier": 5.0
4018 }
4019}
4020```
4021
4022## Terminal: Toolbar
4023
4024- Description: Whether or not to show various elements in the terminal toolbar.
4025- Setting: `toolbar`
4026- Default:
4027
4028```json [settings]
4029{
4030 "terminal": {
4031 "toolbar": {
4032 "breadcrumbs": false
4033 }
4034 }
4035}
4036```
4037
4038**Options**
4039
4040At the moment, only the `breadcrumbs` option is available, it controls displaying of the terminal title that can be changed via `PROMPT_COMMAND`.
4041
4042If the terminal title is empty, the breadcrumbs won't be shown.
4043
4044The shell running in the terminal needs to be configured to emit the title.
4045
4046Example command to set the title: `echo -e "\e]2;New Title\007";`
4047
4048### Terminal: Button
4049
4050- Description: Control to show or hide the terminal button in the status bar
4051- Setting: `button`
4052- Default: `true`
4053
4054**Options**
4055
4056`boolean` values
4057
4058```json [settings]
4059{
4060 "terminal": {
4061 "button": false
4062 }
4063}
4064```
4065
4066### Terminal: Working Directory
4067
4068- Description: What working directory to use when launching the terminal.
4069- Setting: `working_directory`
4070- Default: `"current_project_directory"`
4071
4072**Options**
4073
40741. Use the current file's project directory. Will Fallback to the first project directory strategy if unsuccessful
4075
4076```json [settings]
4077{
4078 "terminal": {
4079 "working_directory": "current_project_directory"
4080 }
4081}
4082```
4083
40842. Use the first project in this workspace's directory. Will fallback to using this platform's home directory.
4085
4086```json [settings]
4087{
4088 "terminal": {
4089 "working_directory": "first_project_directory"
4090 }
4091}
4092```
4093
40943. Always use this platform's home directory (if we can find it)
4095
4096```json [settings]
4097{
4098 "terminal": {
4099 "working_directory": "always_home"
4100 }
4101}
4102```
4103
41044. 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.
4105
4106```json [settings]
4107{
4108 "terminal": {
4109 "working_directory": {
4110 "always": {
4111 "directory": "~/zed/projects/"
4112 }
4113 }
4114 }
4115}
4116```
4117
4118## REPL
4119
4120- Description: Repl settings.
4121- Setting: `repl`
4122- Default:
4123
4124```json [settings]
4125"repl": {
4126 // Maximum number of columns to keep in REPL's scrollback buffer.
4127 // Clamped with [20, 512] range.
4128 "max_columns": 128,
4129 // Maximum number of lines to keep in REPL's scrollback buffer.
4130 // Clamped with [4, 256] range.
4131 "max_lines": 32
4132},
4133```
4134
4135## Theme
4136
4137- 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.
4138- Setting: `theme`
4139- Default: `One Dark`
4140
4141### Theme Object
4142
4143- Description: Specify the theme using an object that includes the `mode`, `dark`, and `light` themes.
4144- Setting: `theme`
4145- Default:
4146
4147```json [settings]
4148"theme": {
4149 "mode": "system",
4150 "dark": "One Dark",
4151 "light": "One Light"
4152},
4153```
4154
4155### Mode
4156
4157- Description: Specify theme mode.
4158- Setting: `mode`
4159- Default: `system`
4160
4161**Options**
4162
41631. Set the theme to dark mode
4164
4165```json [settings]
4166{
4167 "mode": "dark"
4168}
4169```
4170
41712. Set the theme to light mode
4172
4173```json [settings]
4174{
4175 "mode": "light"
4176}
4177```
4178
41793. Set the theme to system mode
4180
4181```json [settings]
4182{
4183 "mode": "system"
4184}
4185```
4186
4187### Dark
4188
4189- Description: The name of the dark Zed theme to use for the UI.
4190- Setting: `dark`
4191- Default: `One Dark`
4192
4193**Options**
4194
4195Run the {#action theme_selector::Toggle} action in the command palette to see a current list of valid themes names.
4196
4197### Light
4198
4199- Description: The name of the light Zed theme to use for the UI.
4200- Setting: `light`
4201- Default: `One Light`
4202
4203**Options**
4204
4205Run the {#action theme_selector::Toggle} action in the command palette to see a current list of valid themes names.
4206
4207## Title Bar
4208
4209- Description: Whether or not to show various elements in the title bar
4210- Setting: `title_bar`
4211- Default:
4212
4213```json [settings]
4214"title_bar": {
4215 "show_branch_icon": false,
4216 "show_branch_name": true,
4217 "show_project_items": true,
4218 "show_onboarding_banner": true,
4219 "show_user_picture": true,
4220 "show_sign_in": true,
4221 "show_menus": false
4222}
4223```
4224
4225**Options**
4226
4227- `show_branch_icon`: Whether to show the branch icon beside branch switcher in the titlebar
4228- `show_branch_name`: Whether to show the branch name button in the titlebar
4229- `show_project_items`: Whether to show the project host and name in the titlebar
4230- `show_onboarding_banner`: Whether to show onboarding banners in the titlebar
4231- `show_user_picture`: Whether to show user picture in the titlebar
4232- `show_sign_in`: Whether to show the sign in button in the titlebar
4233- `show_menus`: Whether to show the menus in the titlebar
4234
4235## Vim
4236
4237- Description: Whether or not to enable vim mode.
4238- Setting: `vim_mode`
4239- Default: `false`
4240
4241## When Closing With No Tabs
4242
4243- Description: Whether the window should be closed when using 'close active item' on a window with no tabs
4244- Setting: `when_closing_with_no_tabs`
4245- Default: `"platform_default"`
4246
4247**Options**
4248
42491. Use platform default behavior:
4250
4251```json [settings]
4252{
4253 "when_closing_with_no_tabs": "platform_default"
4254}
4255```
4256
42572. Always close the window:
4258
4259```json [settings]
4260{
4261 "when_closing_with_no_tabs": "close_window"
4262}
4263```
4264
42653. Never close the window:
4266
4267```json [settings]
4268{
4269 "when_closing_with_no_tabs": "keep_window_open"
4270}
4271```
4272
4273## Project Panel
4274
4275- Description: Customize project panel
4276- Setting: `project_panel`
4277- Default:
4278
4279```json [settings]
4280{
4281 "project_panel": {
4282 "button": true,
4283 "default_width": 240,
4284 "dock": "left",
4285 "entry_spacing": "comfortable",
4286 "file_icons": true,
4287 "folder_icons": true,
4288 "git_status": true,
4289 "indent_size": 20,
4290 "auto_reveal_entries": true,
4291 "auto_fold_dirs": true,
4292 "drag_and_drop": true,
4293 "scrollbar": {
4294 "show": null
4295 },
4296 "sticky_scroll": true,
4297 "show_diagnostics": "all",
4298 "indent_guides": {
4299 "show": "always"
4300 },
4301 "hide_root": false,
4302 "hide_hidden": false,
4303 "starts_open": true,
4304 "auto_open": {
4305 "on_create": true,
4306 "on_paste": true,
4307 "on_drop": true
4308 }
4309 }
4310}
4311```
4312
4313### Dock
4314
4315- Description: Control the position of the dock
4316- Setting: `dock`
4317- Default: `left`
4318
4319**Options**
4320
43211. Default dock position to left
4322
4323```json [settings]
4324{
4325 "dock": "left"
4326}
4327```
4328
43292. Default dock position to right
4330
4331```json [settings]
4332{
4333 "dock": "right"
4334}
4335```
4336
4337### Entry Spacing
4338
4339- Description: Spacing between worktree entries
4340- Setting: `entry_spacing`
4341- Default: `comfortable`
4342
4343**Options**
4344
43451. Comfortable entry spacing
4346
4347```json [settings]
4348{
4349 "entry_spacing": "comfortable"
4350}
4351```
4352
43532. Standard entry spacing
4354
4355```json [settings]
4356{
4357 "entry_spacing": "standard"
4358}
4359```
4360
4361### Git Status
4362
4363- Description: Indicates newly created and updated files
4364- Setting: `git_status`
4365- Default: `true`
4366
4367**Options**
4368
43691. Default enable git status
4370
4371```json [settings]
4372{
4373 "git_status": true
4374}
4375```
4376
43772. Default disable git status
4378
4379```json [settings]
4380{
4381 "git_status": false
4382}
4383```
4384
4385### Default Width
4386
4387- Description: Customize default width taken by project panel
4388- Setting: `default_width`
4389- Default: `240`
4390
4391**Options**
4392
4393`float` values
4394
4395### Auto Reveal Entries
4396
4397- Description: Whether to reveal it in the project panel automatically, when a corresponding project entry becomes active. Gitignored entries are never auto revealed.
4398- Setting: `auto_reveal_entries`
4399- Default: `true`
4400
4401**Options**
4402
44031. Enable auto reveal entries
4404
4405```json [settings]
4406{
4407 "auto_reveal_entries": true
4408}
4409```
4410
44112. Disable auto reveal entries
4412
4413```json [settings]
4414{
4415 "auto_reveal_entries": false
4416}
4417```
4418
4419### Auto Fold Dirs
4420
4421- Description: Whether to fold directories automatically when directory has only one directory inside.
4422- Setting: `auto_fold_dirs`
4423- Default: `true`
4424
4425**Options**
4426
44271. Enable auto fold dirs
4428
4429```json [settings]
4430{
4431 "auto_fold_dirs": true
4432}
4433```
4434
44352. Disable auto fold dirs
4436
4437```json [settings]
4438{
4439 "auto_fold_dirs": false
4440}
4441```
4442
4443### Indent Size
4444
4445- Description: Amount of indentation (in pixels) for nested items.
4446- Setting: `indent_size`
4447- Default: `20`
4448
4449### Indent Guides: Show
4450
4451- Description: Whether to show indent guides in the project panel.
4452- Setting: `indent_guides`
4453- Default:
4454
4455```json [settings]
4456"indent_guides": {
4457 "show": "always"
4458}
4459```
4460
4461**Options**
4462
44631. Show indent guides in the project panel
4464
4465```json [settings]
4466{
4467 "indent_guides": {
4468 "show": "always"
4469 }
4470}
4471```
4472
44732. Hide indent guides in the project panel
4474
4475```json [settings]
4476{
4477 "indent_guides": {
4478 "show": "never"
4479 }
4480}
4481```
4482
4483### Scrollbar: Show
4484
4485- 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.
4486- Setting: `scrollbar`
4487- Default:
4488
4489```json [settings]
4490"scrollbar": {
4491 "show": null
4492}
4493```
4494
4495**Options**
4496
44971. Show scrollbar in the project panel
4498
4499```json [settings]
4500{
4501 "scrollbar": {
4502 "show": "always"
4503 }
4504}
4505```
4506
45072. Hide scrollbar in the project panel
4508
4509```json [settings]
4510{
4511 "scrollbar": {
4512 "show": "never"
4513 }
4514}
4515```
4516
4517### Auto Open
4518
4519- Description: Control whether files are opened automatically after different creation flows in the project panel.
4520- Setting: `auto_open`
4521- Default:
4522
4523```json [settings]
4524"auto_open": {
4525 "on_create": true,
4526 "on_paste": true,
4527 "on_drop": true
4528}
4529```
4530
4531**Options**
4532
4533- `on_create`: Whether to automatically open newly created files in the editor.
4534- `on_paste`: Whether to automatically open files after pasting or duplicating them.
4535- `on_drop`: Whether to automatically open files dropped from external sources.
4536
4537## Agent
4538
4539Visit [the Configuration page](./ai/configuration.md) under the AI section to learn more about all the agent-related settings.
4540
4541## Collaboration Panel
4542
4543- Description: Customizations for the collaboration panel.
4544- Setting: `collaboration_panel`
4545- Default:
4546
4547```json [settings]
4548{
4549 "collaboration_panel": {
4550 "button": true,
4551 "dock": "left",
4552 "default_width": 240
4553 }
4554}
4555```
4556
4557**Options**
4558
4559- `button`: Whether to show the collaboration panel button in the status bar
4560- `dock`: Where to dock the collaboration panel. Can be `left` or `right`
4561- `default_width`: Default width of the collaboration panel
4562
4563## Debugger
4564
4565- Description: Configuration for debugger panel and settings
4566- Setting: `debugger`
4567- Default:
4568
4569```json [settings]
4570{
4571 "debugger": {
4572 "stepping_granularity": "line",
4573 "save_breakpoints": true,
4574 "dock": "bottom",
4575 "button": true
4576 }
4577}
4578```
4579
4580See the [debugger page](./debugger.md) for more information about debugging support within Zed.
4581
4582## Git Panel
4583
4584- Description: Setting to customize the behavior of the git panel.
4585- Setting: `git_panel`
4586- Default:
4587
4588```json [settings]
4589{
4590 "git_panel": {
4591 "button": true,
4592 "dock": "left",
4593 "default_width": 360,
4594 "status_style": "icon",
4595 "fallback_branch_name": "main",
4596 "sort_by_path": false,
4597 "collapse_untracked_diff": false,
4598 "scrollbar": {
4599 "show": null
4600 }
4601 }
4602}
4603```
4604
4605**Options**
4606
4607- `button`: Whether to show the git panel button in the status bar
4608- `dock`: Where to dock the git panel. Can be `left` or `right`
4609- `default_width`: Default width of the git panel
4610- `status_style`: How to display git status. Can be `label_color` or `icon`
4611- `fallback_branch_name`: What branch name to use if `init.defaultBranch` is not set
4612- `sort_by_path`: Whether to sort entries in the panel by path or by status (the default)
4613- `collapse_untracked_diff`: Whether to collapse untracked files in the diff panel
4614- `scrollbar`: When to show the scrollbar in the git panel
4615
4616## Outline Panel
4617
4618- Description: Customize outline Panel
4619- Setting: `outline_panel`
4620- Default:
4621
4622```json [settings]
4623"outline_panel": {
4624 "button": true,
4625 "default_width": 300,
4626 "dock": "left",
4627 "file_icons": true,
4628 "folder_icons": true,
4629 "git_status": true,
4630 "indent_size": 20,
4631 "auto_reveal_entries": true,
4632 "auto_fold_dirs": true,
4633 "indent_guides": {
4634 "show": "always"
4635 },
4636 "scrollbar": {
4637 "show": null
4638 }
4639}
4640```
4641
4642## Calls
4643
4644- Description: Customize behavior when participating in a call
4645- Setting: `calls`
4646- Default:
4647
4648```json [settings]
4649"calls": {
4650 // Join calls with the microphone live by default
4651 "mute_on_join": false,
4652 // Share your project when you are the first to join a channel
4653 "share_on_join": false
4654},
4655```
4656
4657## Unnecessary Code Fade
4658
4659- Description: How much to fade out unused code.
4660- Setting: `unnecessary_code_fade`
4661- Default: `0.3`
4662
4663**Options**
4664
4665Float values between `0.0` and `0.9`, where:
4666
4667- `0.0` means no fading (unused code looks the same as used code)
4668- `0.9` means maximum fading (unused code is very faint but still visible)
4669
4670**Example**
4671
4672```json [settings]
4673{
4674 "unnecessary_code_fade": 0.5
4675}
4676```
4677
4678## UI Font Family
4679
4680- Description: The name of the font to use for text in the UI.
4681- Setting: `ui_font_family`
4682- Default: `.ZedSans`. This currently aliases to [IBM Plex](https://www.ibm.com/plex/).
4683
4684**Options**
4685
4686The 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).
4687
4688## UI Font Features
4689
4690- Description: The OpenType features to enable for text in the UI.
4691- Setting: `ui_font_features`
4692- Default:
4693
4694```json [settings]
4695"ui_font_features": {
4696 "calt": false
4697}
4698```
4699
4700- Platform: macOS and Windows.
4701
4702**Options**
4703
4704Zed supports all OpenType features that can be enabled or disabled for a given UI font, as well as setting values for font features.
4705
4706For example, to disable font ligatures, add the following to your settings:
4707
4708```json [settings]
4709{
4710 "ui_font_features": {
4711 "calt": false
4712 }
4713}
4714```
4715
4716You can also set other OpenType features, like setting `cv01` to `7`:
4717
4718```json [settings]
4719{
4720 "ui_font_features": {
4721 "cv01": 7
4722 }
4723}
4724```
4725
4726## UI Font Fallbacks
4727
4728- Description: The font fallbacks to use for text in the UI.
4729- Setting: `ui_font_fallbacks`
4730- Default: `null`
4731- Platform: macOS and Windows.
4732
4733**Options**
4734
4735For example, to use `Nerd Font` as a fallback, add the following to your settings:
4736
4737```json [settings]
4738{
4739 "ui_font_fallbacks": ["Nerd Font"]
4740}
4741```
4742
4743## UI Font Size
4744
4745- Description: The default font size for text in the UI.
4746- Setting: `ui_font_size`
4747- Default: `16`
4748
4749**Options**
4750
4751`integer` values from `6` to `100` pixels (inclusive)
4752
4753## UI Font Weight
4754
4755- Description: The default font weight for text in the UI.
4756- Setting: `ui_font_weight`
4757- Default: `400`
4758
4759**Options**
4760
4761`integer` values between `100` and `900`
4762
4763## Settings Profiles
4764
4765- Description: Configure any number of settings profiles that are temporarily applied on top of your existing user settings when selected from `settings profile selector: toggle`.
4766- Setting: `profiles`
4767- Default: `{}`
4768
4769In your `settings.json` file, add the `profiles` object.
4770Each key within this object is the name of a settings profile, and each value is an object that can include any of Zed's settings.
4771
4772Example:
4773
4774```json [settings]
4775"profiles": {
4776 "Presenting (Dark)": {
4777 "agent_buffer_font_size": 18.0,
4778 "buffer_font_size": 18.0,
4779 "theme": "One Dark",
4780 "ui_font_size": 18.0
4781 },
4782 "Presenting (Light)": {
4783 "agent_buffer_font_size": 18.0,
4784 "buffer_font_size": 18.0,
4785 "theme": "One Light",
4786 "ui_font_size": 18.0
4787 },
4788 "Writing": {
4789 "agent_buffer_font_size": 15.0,
4790 "buffer_font_size": 15.0,
4791 "theme": "Catppuccin Frappé - No Italics",
4792 "ui_font_size": 15.0,
4793 "tab_bar": { "show": false },
4794 "toolbar": { "breadcrumbs": false }
4795 }
4796}
4797```
4798
4799To preview and enable a settings profile, open the command palette via {#kb command_palette::Toggle} and search for `settings profile selector: toggle`.
4800
4801## An example configuration:
4802
4803```json [settings]
4804// ~/.config/zed/settings.json
4805{
4806 "theme": "cave-light",
4807 "tab_size": 2,
4808 "preferred_line_length": 80,
4809 "soft_wrap": "none",
4810
4811 "buffer_font_size": 18,
4812 "buffer_font_family": ".ZedMono",
4813
4814 "autosave": "on_focus_change",
4815 "format_on_save": "off",
4816 "vim_mode": false,
4817 "projects_online_by_default": true,
4818 "terminal": {
4819 "font_family": "FiraCode Nerd Font Mono",
4820 "blinking": "off"
4821 },
4822 "languages": {
4823 "C": {
4824 "format_on_save": "on",
4825 "formatter": "language_server",
4826 "preferred_line_length": 64,
4827 "soft_wrap": "preferred_line_length"
4828 }
4829 }
4830}
4831```