next-upgrade

Upgrades Next.js projects to newer versions using official migration guides and codemods.

Updated Jun 8, 2026
One-click install
npx skills add https://github.com/raulisai/eva02 --skill next-upgrade-raulisai
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: next-upgrade
Source: https://github.com/raulisai/eva02/tree/main/.agents/skills/next-upgrade
Command: npx skills add https://github.com/raulisai/eva02 --skill next-upgrade-raulisai

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Upgrading Next.js across major versions involves breaking API changes, deprecated features, and dependency conflicts that are tedious and error-prone to handle manually. This Skill automates the upgrade workflow by detecting the current version, fetching official migration guides, and applying codemods. ## Core Features & Use Cases - Version Detection and Upgrade Path Planning: Reads package.json to identify the current Next.js version and plans incremental upgrades across major versions (e.g., 13 → 14 → 15). - Official Codemod Execution: Runs @next/codemod transforms such as next-async-request-api and next-request-geo-ip to automate breaking-change migrations. - Dependency and Type Updates: Upgrades next, react, react-dom, and their TypeScript type packages together, then validates with build and dev commands. - Use Case: A team maintaining a Next.js 14 dashboard wants to move to Next.js 15. The Skill detects the version, fetches the v15 migration guide, runs the async request API codemod, updates dependencies, and verifies the build. ## Quick Start Ask the assistant to upgrade this project's Next.js version to the latest release following the official migration guides.

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 version?

Detect your current version in package.json, fetch the official upgrade guide for your target version, run the relevant @next/codemod transforms, then update next, react, and react-dom together with npm install. Finish by running your build and dev commands to verify.

How to run Next.js codemods for breaking changes?

Run npx @next/codemod@latest <transform> <path> with the transform matching your target version. Common transforms include next-async-request-api for async Request APIs in v15 and next-request-geo-ip for geo/ip property migration.

Can I upgrade Next.js across multiple major versions at once?

No, upgrades should be incremental across major versions, such as 13 to 14 to 15. Each major version has its own migration guide and codemods, and skipping steps risks missing breaking changes that codemods would otherwise handle.

Does upgrading Next.js require updating React and TypeScript types?

Yes, Next.js and its peer dependencies should be upgraded together. Install next, react, and react-dom at matching latest versions, and update @types/react and @types/react-dom if your project uses TypeScript.

Why does my build fail after a Next.js upgrade?

Build failures usually come from unapplied breaking changes such as async params in v15, outdated next.config.js options, or removed deprecated features. Check the version-specific migration guide for manual changes that codemods do not cover.