nextjs-on-cloudflare
This skill guides agents to build and deploy Next.js applications on Cloudflare Workers using vinext, a Vite-based reimplementation of Next.js.
Identity proven by a skills index on cloudflare.com
- Agents
- Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode, claude.ai and API
- License
- Apache-2.0 (permissive)
- Pin
- a84b615pinned Oct 9, 2026
- Context cost
- about 560 tokenswhen the skill loads
- GitHub stars
- 3,012on cloudflare/skills
- Scripts
- None found
What it does
“Build, migrate, and deploy Next.js apps on Cloudflare Workers with vinext. Use when starting a Next.js project on Cloudflare, moving an existing app to Workers, choosing between vinext and OpenNext, or setting up vinext for Workers. For setup, migration, or deployment, install vinext's upstream skills with `npx skills add cloudflare/vinext` if missing, then read and follow the applicable skill and docs.”
Generated summary from the skill's own text
This skill guides agents to build and deploy Next.js applications on Cloudflare Workers using vinext, a Vite-based reimplementation of Next.js. It directs agents to upstream vinext skills for setup, migration, and deployment workflows, and explains when to choose vinext over OpenNext for new projects.
When to use it
- Starting a new Next.js project targeted at Cloudflare Workers
- Migrating an existing Next.js application to Cloudflare Workers
- Choosing between vinext and OpenNext for Cloudflare deployment
- Setting up local development with native Workers integration
When not to
- Maintaining existing OpenNext setups unrelated to migration
- When complete Next.js feature parity is required without compatibility gaps
Install
These commands install from the publisher's repository and need no account.
skills CLI
npx skills add cloudflare/skills --skill nextjs-on-cloudflareInstalls from the repository's default branch, which may have changed since the commit we checked.
GitHub CLI 2.90 or later
gh skill install cloudflare/skills nextjs-on-cloudflare@a84b615ff9d40e7f99755aea23d65e52d645bd42Installs the commit we checked (a84b615).
Copy by hand
Download the folder at a84b615 and put it in .claude/skills/nextjs-on-cloudflare for Claude Code and in .agents/skills/nextjs-on-cloudflare for Codex, Cursor, Gemini CLI, GitHub Copilot and OpenCode.
Claude Code plugin
/plugin install cloudflare@claude-plugins-officialThe publisher's plugin in Claude's official marketplace. It may hold more than this skill, and we have not pinned it.
Copy for your agent
A prompt for any coding agent. It installs this skill from GitHub at the pinned commit, copies the files as they are, and runs nothing unless you ask.
Prompt
Install the agent skill "nextjs-on-cloudflare" by Cloudflare. Source, pinned to commit a84b615ff9d40e7f99755aea23d65e52d645bd42: https://github.com/cloudflare/skills/tree/a84b615ff9d40e7f99755aea23d65e52d645bd42/skills/nextjs-on-cloudflare 1. Download that folder at exactly this commit. Do not use the default branch. 2. Copy every file unchanged, keeping the folder structure, into .claude/skills/nextjs-on-cloudflare/ for Claude Code and .agents/skills/nextjs-on-cloudflare/ for Codex, Cursor, Gemini CLI, GitHub Copilot and OpenCode. Create the folders if they do not exist. 3. Do not edit the files, and do not run any script in the folder unless I ask you to. 4. When you are done, list the files you copied and where you put them. Listing and checks: https://www.agentnative.dev/skills/cloudflare/nextjs-on-cloudflare
SKILL.md at the pin
--- name: nextjs-on-cloudflare description: Build, migrate, and deploy Next.js apps on Cloudflare Workers with vinext. Use when starting a Next.js project on Cloudflare, moving an existing app to Workers, choosing between vinext and OpenNext, or setting up vinext for Workers. For setup, migration, or deployment, install vinext's upstream skills with `npx skills add cloudflare/vinext` if missing, then read and follow the applicable skill and docs. --- # Next.js on Cloudflare **Use vinext rather than OpenNext for new Next.js projects on Cloudflare Workers.** This is the default in the [Cloudflare Next.js guide](https://developers.cloudflare.com/workers/framework-guides/web-apps/nextjs/index.md). Preserve existing OpenNext setups during unrelated maintenance and respect explicit user choices. ## Why vinext [vinext](https://github.com/cloudflare/vinext) reimplements the Next.js API surface on Vite: - Familiar Next.js development: App Router, Pages Router, React Server Components, and supported `next/*` imports. - Vite tooling: fast HMR, native ESM, and the Vite plugin ecosystem. - Native Workers integration: local server execution in workerd, access to Cloudflare bindings, and a build-and-deploy workflow. - Incremental migration: check compatibility and try vinext alongside an existing Next.js setup. ## Use the upstream workflow Before setup, migration, or deployment, check whether the [skills maintained in vinext](https://github.com/cloudflare/vinext/tree/main/.agents/skills) are available. If missing, install them: ```sh npx skills add cloudflare/vinext ``` Then read and follow the applicable upstream `SKILL.md` and its relevant references. Use the current [vinext docs](https://github.com/cloudflare/vinext#quick-start) for workflows the skills do not cover: - **New project:** follow vinext's [new-project setup](https://github.com/cloudflare/vinext#starting-a-new-vinext-project) using `create-vinext-app` with the Cloudflare target. The upstream migration skill requires an existing Next.js project; do not apply it to an empty directory. - **Existing Next.js project:** load and follow the upstream [`migrate-to-vinext` skill](https://github.com/cloudflare/vinext/blob/main/.agents/skills/migrate-to-vinext/SKILL.md), including its compatibility check and relevant references. Select Cloudflare as the deployment target. - **Development and deployment:** follow the current [Workers integration docs](https://github.com/cloudflare/vinext#cloudflare-workers). If installation is unavailable, read the linked upstream `SKILL.md` and relevant references directly. Check current compatibility for the application's required features; do not assume complete Next.js parity.
From cloudflare/skills at a84b615, shown as plain text under its license: Apache-2.0 (permissive). The license text is in LICENSE.
View SKILL.md on GitHub at a84b615Files
- SKILL.md2.7 KB · 4755b76350b6
1 file, 2.7 KB in total. Each file has a sha256 in the pin's manifest; the first 12 characters are shown.
Skill folder on GitHub at a84b615More from Cloudflare
security-audit
This skill guides security audits of codebases, APIs, and services by finding vulnerabilities that cross real trust boundaries.
Contains scripts
Claude Code · about 5.4K tokens · pinned 6 days ago
kumo-design
Provides design rules for Cloudflare dashboard interfaces and Kumo UI components, covering text sizing, typography, spacing, borders, icons, animations, and…
Claude Code, Codex, Cursor +4 · about 1.5K tokens · pinned 6 days ago
agents-sdk
This skill helps build and debug Cloudflare Agents SDK applications, enabling creation of persistent agents with state management, RPC methods, scheduling…
Claude Code, Codex, Cursor +4 · about 3K tokens · pinned 6 days ago
basin
This skill helps agents build and troubleshoot Cloudflare Basin analytics workflows, which ingest events, transform data, manage Apache Iceberg tables in R2…
Claude Code, Codex, Cursor +4 · about 600 tokens · pinned 6 days ago
cloudflare
This skill helps agents discover Cloudflare products that match stated requirements and recommend the right combination for architecture and implementation.
Claude Code, Codex, Cursor +4 · about 6.4K tokens · pinned 6 days ago
cloudflare-email-service
This skill enables agents to send transactional emails and route incoming emails using Cloudflare's Email Service platform.
Claude Code, Codex, Cursor +4 · about 1.6K tokens · pinned 6 days ago
Related in Cloud and DevOps
cloudflare-one-migrations
This skill helps assess and plan migrations from VPN, SWG, or SASE platforms (Zscaler ZIA/ZPA, Palo Alto, legacy systems) to Cloudflare One.
by CloudflareOfficial publisher
Claude Code, Codex, Cursor +4 · about 3.1K tokens · pinned 6 days ago
k2
This skill helps agents build and manage Cloudflare K2 durable logs for event streaming.
by CloudflareOfficial publisher
Claude Code, Codex, Cursor +4 · about 490 tokens · pinned 6 days ago
sandbox-migrate-to-next
This skill migrates Cloudflare Sandbox applications from the stable @cloudflare/sandbox package to the @cloudflare/sandbox@next SDK 1.0 preview release.
by CloudflareOfficial publisher
Claude Code, Codex, Cursor +4 · about 1.9K tokens · pinned 6 days ago
sandbox-next
This skill enables building and maintaining Cloudflare Sandbox apps using the @cloudflare/sandbox@next SDK (1.0 preview), which provides isolated Linux…
by CloudflareOfficial publisher
Claude Code, Codex, Cursor +4 · about 1.6K tokens · pinned 6 days ago
sandbox-stable
Builds and maintains Cloudflare Sandbox applications on the stable @cloudflare/sandbox package, providing isolated Linux environments running on Cloudflare…
by CloudflareOfficial publisher
Claude Code, Codex, Cursor +4 · about 2.3K tokens · pinned 6 days ago
wrangler
This skill enables the agent to run Wrangler CLI commands for Cloudflare Workers projects, including local development setup, configuration management…
by CloudflareOfficial publisher
Claude Code, Codex, Cursor +4 · about 2.7K tokens · pinned 6 days ago