---
title: 🔍 Zsh Lint
description: Start using Zsh Lint, understand which files it checks, and find focused guides.
canonical_url: https://wiki.zshell.dev/community/zsh_lint
markdown_url: https://wiki.zshell.dev/community/zsh_lint/index.md
locale: en
source_path: community/04_zsh_lint/index.mdx
---

<!-- Generated from the canonical Z-Shell Wiki build. The linked human-facing page remains the editorial source of truth. -->

# 🔍 Zsh Lint

`zsh-lint` is a standalone semantic analyzer for Zsh. Give it one or more source-file paths and it reports parser errors, correctness problems, and advisory findings in a greppable format.

<a id="try-it-in-five-minutes"></a>

## Try it in five minutes

Install the current published release with an exact version:

```sh
go install github.com/z-shell/zsh-lint/cmd/zsh-lint@v1.6.1
```

Then check a file:

```sh
zsh-lint path/to/script.zsh
```

If Go's binary directory is not already on your `PATH`, run the installed binary as `"$(go env GOPATH)/bin/zsh-lint"`.

:::important File recognition The published CLI does not inspect a shebang, require a `.zsh` extension, scan directories, or discover source files. Every explicit path is treated as Zsh source. Only the `zsh-lint.json` project configuration is discovered automatically; see [Project configuration](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-project-configuration/index.md). An extensionless autoloaded function works when you name it directly, while a Bash file is still parsed as Zsh if you pass its path. :::

For parser-only corpus evaluation without lint rules, use the advanced [`zsh-lint-survey`](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-parser-survey/index.md) command.

<a id="choose-a-guide"></a>

## Choose a guide

[![](https://wiki.zshell.dev/img/svg/cards/packages.svg)

### Getting started

Install a pinned release, lint a small script, and understand the result.

Run the first check →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-getting-started/index.md)[![](https://wiki.zshell.dev/img/svg/cards/history-search.svg)

### Choosing files

Learn how explicit paths, shebangs, extensions, directories, and mixed shell repositories behave.

Select inputs →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-choosing-files/index.md)[![](https://wiki.zshell.dev/img/svg/cards/annexes.svg)

### Project configuration

Describe plugins and multi-profile projects in a `zsh-lint.json` that the CLI discovers automatically.

Configure a project →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-project-configuration/index.md)[![](https://wiki.zshell.dev/img/svg/cards/flexible.svg)

### Rules and suppressions

Read diagnostics and document intentional exceptions without hiding other rules.

Handle findings →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-rules-and-suppressions/index.md)[![](https://wiki.zshell.dev/img/svg/cards/ecosystem.svg)

### CI and JSON

Add a reproducible GitHub Actions check and consume structured output.

Automate checks →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-ci-and-json/index.md)[![](https://wiki.zshell.dev/img/svg/cards/zi-console.svg)

### Troubleshooting

Resolve install, input, parser, exit-code, and configuration surprises.

Fix common problems →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-troubleshooting/index.md)[![](https://wiki.zshell.dev/img/svg/cards/speed.svg)

### Parser survey

Use the advanced parser-coverage command without running lint rules.

Survey a corpus →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-parser-survey/index.md)[![](https://wiki.zshell.dev/img/svg/cards/syntax-highlighting.svg)

### Published rule reference

See the readable rule set generated from the latest published release.

Browse rules →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-rule-reference/index.md)[![](https://wiki.zshell.dev/img/svg/cards/meta-plugins.svg)

### MCP server

Run the stdio JSON-RPC server to provide static diagnostics and native syntax checks to MCP clients.

Serve analysis →](https://wiki.zshell.dev/community/zsh_lint/zsh-lint-mcp-server/index.md)

<a id="published-behavior"></a>

## Published behavior

The guides describe v1.6.1, which includes project configuration, automatic `zsh-lint.json` discovery, and an MCP server. Automatic source-file discovery and shebang-based classification are not implemented; that design is tracked in [zsh-lint issue 183](https://github.com/z-shell/zsh-lint/issues/183).

Source code and development status live in [z-shell/zsh-lint](https://github.com/z-shell/zsh-lint).
