Configuring Zed

Zed can be configured via a simple JSON file located at ~/.zed/settings.json.

Opening your settings file

You can open ~/.zed/settings.json via cmd-,, the command palette, or the Zed > Open Settings application menu item.

This file contains a JSON object and should look like this:

{
  "theme": "rosé-pine",
  "buffer_font_family": "PragmataPro Liga",
  "buffer_font_size": 16
}

Add entries to a JSON object in this file and save it to configure Zed.

Available settings

OptionDefaultDescription
themecave-darkTheme name Sets the startup theme.
buffer_font_familyzed-monoFont name The editor font family.
buffer_font_size16Number The editor font size.
tab_size4Number Spaces per tab.
preferred_line_length80?
format_on_savetrueBoolean Formats open buffer on save.
language_overridesnullSee Overrides below.
soft_wrapeditor_widtheditor_width, none, preferred_line_length
vim_modefalseBoolean Enables Vim mode (WIP - see Vim mode)
projects_online_by_defaulttrueBoolean Project goes online when opened.

Overrides

You can override settings for specific languages like this:

"language_overrides": {
  "C": {
    "format_on_save": false,
    "preferred_line_length": 64,
    "soft_wrap": "preferred_line_length"
  },
  "JSON": {
    "tab_size": 4
  }
}

For a complete list of languages you can override settings for see Supported Languages.

An example configuration:

// ~/.zed/settings.json
{
  "theme": "cave-light",
  "tab_size": 2,
  "preferred_line_length": 80,
  "soft_wrap": "none",

  "buffer_font_size": 18,
  "buffer_font_family": "Zed Mono",

  "format_on_save": false,
  "vim_mode": false,
  "projects_online_by_default": true,

  "language_overrides": {
    "C": {
      "format_on_save": false,
      "preferred_line_length": 64,
      "soft_wrap": "preferred_line_length"
    }
  }
}