
About Prettier
Prettier is an opinionated code formatter. It rewrites your code in one consistent style, so teams spend less time discussing formatting in code review.
What it does
Prettier reads your code and prints it again with consistent spacing, line breaks and quotes. It supports many languages, including JavaScript, TypeScript, JSON, CSS, HTML and Markdown. Most editors can run it on save. It has only a few options, so most projects use the defaults and spend little time on setup.
Key features
- Formats JavaScript, TypeScript, JSON and CSS
- Formats Markdown, YAML and GraphQL files
- Runs on save in most popular editors
- Few options, so setup stays short
- Plugins for languages such as Java, PHP and Ruby
Who it's for
Web developers and frontend teams who want formatting decided by a tool rather than by review comments. It also suits teams that work across front-end and back-end languages in the same repository.
Pricing and good to know
Prettier is open source under the MIT licence and free to use. The project accepts donations to fund its maintenance. Some languages are supported through community plugins rather than the core package.
Highlights
- Format JavaScript, TypeScript, JSON and CSS
- Format Markdown, YAML and GraphQL files
- Format files automatically on save in editors
- Keep formatting consistent without many options
- Use community plugins for languages like Java and PHP












