next-upgrade

Detect Next.js versions, apply codemods, and update dependencies for major upgrades.

27|9|Updated Jan 4, 2026
One-click install
npx skills add https://github.com/georgekhananaev/claude-skills-vault --skill next-upgrade-georgekhananaev
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: next-upgrade
Source: https://github.com/georgekhananaev/claude-skills-vault/tree/main/.claude/skills/next-upgrade
Command: npx skills add https://github.com/georgekhananaev/claude-skills-vault --skill next-upgrade-georgekhananaev

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps developers upgrade a Next.js project to the latest major version by coordinating version checks, codemod-driven migrations, and dependency updates to reduce manual engineering effort.

Core Features & Use Cases

  • Codemod-guided upgrades: Automatically applies official Next.js codemods to adapt APIs and project structure during upgrades.
  • Dependency and config alignment: Updates Next.js, React, and related packages; adjusts next.config.js and tsconfig when required; ensures type safety and runtime compatibility.
  • Incremental upgrade planning: Proposes safe intermediate versions for major jumps (e.g., 12 → 13 → 14 → 15) and validates each step with builds and tests.
  • Use Case: You maintain a Next.js app from version 12 and want to reach version 15 with minimal manual edits and stable builds.

Quick Start

Provide the target version via the argument hint and run the skill at your project root. The tool will detect current versions, fetch official upgrade guides, apply codemods, update dependencies, and report any manual changes required. Example: target-version: 15.0.0

Frequently Asked Questions about next-upgrade

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I upgrade Next.js to the latest major version safely?

To upgrade Next.js safely, use codemod-driven migrations to automatically adapt APIs, update dependencies like React, and align configuration files while validating builds. This enforces version-aware steps and generates a migration report to minimize manual edits.

What are codemods and how do they work for Next.js migration?

Codemods are automated scripts that transform codebases to adapt APIs and project structures during Next.js migration. They fetch official upgrade guides and apply targeted changes to ensure type safety and runtime compatibility across versions.

Can I upgrade Next.js from version 12 directly to version 15?

Yes, but for large jumps like 12 to 15, incremental upgrade planning proposes safe intermediate versions. This step-by-step approach validates builds and tests at each stage to ensure stable upgrades across major Next.js versions.

How do I align dependencies and config files when upgrading Next.js?

When upgrading Next.js, align dependencies by updating Next.js, React, and related packages together. The process automatically adjusts next.config.js and tsconfig files to ensure type safety and runtime compatibility.

Does upgrading Next.js with codemods require manual code edits?

Upgrading Next.js with codemods minimizes manual edits by automating API transformations and dependency updates, but a migration report will highlight any remaining actionable manual changes required for full compatibility.