linter
A linter is a program that reviews source code without running it and flags suspicious, erroneous, or non-compliant sections.
In plain terms
The linter is the spellchecker for programmers. Just as a word processor underlines a typo in red, the linter underlines what looks like an error or bad practice in the code: for example, a variable you created but never used.
It does not just look for errors but also preserves a unified style. If ten people write code in a team, the linter ensures it looks as if one person wrote it, making it easier to read and take over each other's work.
In the AI era, the linter has taken on a new role: the coding agent also checks its own work with it. The agent writes the code, runs the linter, reads the warnings, and fixes what it found. The linter thus provides fast, cheap, and predictable feedback to the machine as well.
How it works
- The linter reads the source code but does not execute it: it only examines the text and structure.
- It breaks the code into parts and creates an internal outline showing what belongs to what, where each name is created, and where it is used.
- A rule set is run through this draft: each rule describes a known error pattern or style requirement.
- It lists results with the file name, line number, and a brief explanation; it can often fix simpler issues automatically.
- The team decides which rules apply and often sets it so that only modifications passing the linter can be merged into the shared codebase.
An everyday example
You ask a coding agent to write a small program that renames your vacation photos. In the log you see "running lint… 3 warnings fixed": the agent had a linter check its own code and fixed the problems it found before handing the program over to you.
Who is affected
A common misconception
Limits and risks
- It only notices what has a rule: it misses most logical errors, such as when a program calculates a wrong result with valid code.
- It sometimes makes mistakes and flags things that are actually fine; due to excessive false warnings, people tend to ignore them all.
- Some of the rules are a matter of taste, so the team must agree on their settings.
- A coding agent might disable a rule instead of fixing the error, so it is worth checking how it removed the warning.
Similar, but not the same
- code formatter – A code formatter only rearranges the appearance (indentation, spaces, line breaks), while a linter also looks for suspicious spots in the code itself.
- compiler – A compiler turns code into an executable program and mainly rejects what is irregular. Although modern compilers also issue warnings, a linter flags many more risky solutions and style errors, and its rules can be adapted to the team's needs.
- automated testing – The test runs the program and checks the result, while the linter examines only the code text without running it.
Related concepts
static code analysis, code quality, developer tools
style check, automatic repair
code formatter, compiler, automated testing, code review, coding agent
A brief history
The first such program, named lint, was written by Stephen C. Johnson in 1978 at Bell Labs to check programs written in the C language. The name refers to lint that sticks to clothes: the tool collects the small, annoying 'lint' of code.
Where things stand
At the end of 2026, the linter is standard equipment in software development: there is one for almost every programming language, and it is built into code editors and automated checking pipelines. Coding agents also routinely run linters to check their own work.
In the news
- Greptile: DIY AI code reviewer costs $3 to $25 per pull request and still misses the key bugOct 26, 2026 · Code
- CodeAudit AI VS Code extension monitors all developer activityOct 12, 2026 · Code
- Cloudflare presents an agent development lifecycle and AI-driven enforcement of engineering standardsAug 4, 2026 · Code
Also known as
linter · lint · linting · linting · code reviewer · static code analyzer · static code analyzer · lint tool
Sources
This entry was machine-edited and has undergone machine expert review; the “In the news” section updates automatically from Agent Age stories.