Skip to content
masterclassBuddyTech Buzz5 fresh blogs · 5:00 AM IST

Next.js 16+ · Command

next lint

next lint was removed in Next.js 16. Run ESLint or Biome directly from package scripts, and use the migration codemod for existing projects.

Since
v16.0.0

How it works

In Next.js 16 and later, next lint is no longer available. Replace it with a direct ESLint or Biome command in package scripts; use the migration codemod when converting an existing project.

Key points

  • Choose ESLint for a broad rule set or Biome for a fast linter and formatter.
  • Put the selected tool's CLI in a package script rather than using a Next.js wrapper.
  • Existing applications can automate much of the conversion with the official migration codemod.

Common mistakes

  • Do not keep calling next lint; migrate the project to a standalone linter command.
  • Remove the obsolete eslint option from next.config.js.
  • A successful production build does not replace an explicit lint script.

Example: Migrate from next lint

npx @next/codemod@canary next-lint-to-eslint-cli .

Run the migration codemod, then invoke ESLint from a package script.

When to use it

Replace the removed command

Migrating a Next.js 15 or older application

Adopt ESLint or Biome

Choosing a project linter

Run linting explicitly

Controlling CI build steps

Interview questions

QWhat happened to next lint in Next.js 16?

next lint was removed in Next.js 16. Projects should call ESLint or Biome directly through package scripts instead.

Follow-up: How would you migrate an existing project? Run the next-lint-to-eslint-cli codemod, review its changes, and use the resulting ESLint CLI script.

QHow should linting be invoked after the removal?

The command is replaced by direct linter execution. A typical ESLint script is "lint": "eslint", while a Biome script is "lint": "biome check".

Follow-up: Which alternative also formats code? Biome can format with a separate biome format --write script.

QDoes next build still lint automatically?

Next.js 16 does not run linting as part of next build. Linting must be scheduled explicitly, such as through an npm, pnpm, Yarn, or Bun script.

Follow-up: Why is this useful operationally? It lets CI and developers choose when linting runs instead of coupling it to every build.

  • ESLint
  • Biome
  • eslint-config-next
  • next-lint-to-eslint-cli codemod

Source: Configuration: ESLint | Next.js. Checked 2026-10-15.