Prettier
Opinionated code formatter for JavaScript, TypeScript, and related languages.
Linting and formatting npm MIT
Used in agent projects
2,218
17.5% of 12,697 public repos built with AI coding agents
Rank in linting and formatting
#2 of 40
by use in those projects
Downloads
138M
npm, last 7 days, prettier
GitHub stars
52.4K
last push Oct 10, 2026
How Prettier is used
Prettier is a dependency in 2,218 of the 12,697 public GitHub projects set up for AI coding agents that we scanned (17.5%), #2 of 40 in linting and formatting. The most used alternative there is ESLint. Projects that use it most often also use ESLint (74.1%), TypeScript (86.2%), Husky (24.6%).
Often used with Prettier
| ESLint | 74.1% of Prettier projects · 1.9× more than average |
|---|---|
| TypeScript | 86.2% of Prettier projects · 1.5× more than average |
| Husky | 24.6% of Prettier projects · 3.9× more than average |
| lint-staged | 19.6% of Prettier projects · 4.2× more than average |
| Vitest | 27.3% of Prettier projects · 2.2× more than average |
| Tailwind CSS | 45.7% of Prettier projects |
| React | 47.7% of Prettier projects |
| Jest | 15.5% of Prettier projects · 2.8× more than average |
By coding agent
| Claude Code | 22.4% of projects set up for it |
|---|---|
| GitHub Copilot | 22.2% of projects set up for it |
| Cursor | 24.8% of projects set up for it |
| OpenAI Codex | 32.7% of projects set up for it |
| Gemini CLI | 32.0% of projects set up for it |
| OpenCode | 28.1% of projects set up for it |
| Devin Desktop | 22.6% of projects set up for it |
| Kiro | 25.3% of projects set up for it |
Share of public repos configured for each agent that list Prettier as a dependency.
Install
| Package | npm install prettier |
|---|---|
| Packages counted | prettier, prettier-plugin-tailwindcss, prettier-plugin-svelte, prettier-plugin-organize-imports, prettier-plugin-astro, prettier-plugin-solidity, prettier-plugin-packagejson, prettier-plugin-apex |
| Main stacks | TypeScript / JavaScript (1,350), Next.js (513), Rust (166), PHP (80) |
| Example projects | Automattic/wp-calypso, WordPress/gutenberg, NG-ZORRO/ng-zorro-antd, founded-labs/react-native-reusables, enso-org/enso |
Alternatives to Prettier
| Tool | Used in agent projects | Downloads / wk | GitHub stars | License |
|---|---|---|---|---|
| ESLint npm Linter that finds and fixes JavaScript code patterns based on AST analysis. |
4,833 (38.1%) | 162M | 27.6K | MIT |
| Biome npm Fast web toolchain providing linting, formatting and code quality all in one. |
445 (3.5%) | 17.7M | 25.9K | MIT OR Apache-2.0 |
| oxlint npm Fast JavaScript linter written in Rust with zero-config defaults. |
206 (1.6%) | 25.7M | 23K | MIT |
| Knip npm Find and fix unused dependencies, exports and files in TypeScript/JavaScript projects. |
150 (1.2%) | 17.5M | 12.4K | ISC |
| stylelint npm Linter that finds and fixes CSS errors and enforces code style conventions. |
140 (1.1%) | 10.8M | 11.5K | MIT |
| oxfmt npm Fast JavaScript formatter from the Oxc compiler project. |
125 (1.0%) | 16.3M | 23K | MIT |
| ESLint Import Resolver TypeScript npm ESLint plugin resolver adding TypeScript support to import/export linting. |
119 (0.9%) | 48.8M | 825 | ISC |
| Black pypi Uncompromising Python code formatter enforcing consistent style automatically. |
108 (0.9%) | 28.7M | 41.9K | — |