Skip to content

ASSETS binding error on deployment when using the cloudflare_module preset #3515

Closed

Description

@thasmo

Environment

  • node 22.17.1
  • nitro 2.12.4
  • nuxt 4.0.2
  • vite 7.0.6
  • wrangler 4.26.1
  • pnpm 10.13.1

Reproduction

nuxt.config.js

import { defineNuxtConfig } from 'nuxt/config';

export default defineNuxtConfig({
	compatibilityDate: '2025-07-01',
	nitro: {
		cloudflare: {
			deployConfig: true,
			nodeCompat: true,
		},
		preset: 'cloudflare_module',
	},
});

Describe the bug

When deploying a nuxt project on cloudflare, the deployment step fails on cloudflare with the error:

The name 'ASSETS' is reserved in Pages projects. Please use a different name for your Assets binding.

Mind that the cloudflare project is a workers project, not a pages project.

Additional context

The locally built wrangler.json file looks like this:

{
  "compatibility_date": "2025-07-01",
  "name": "project-name",
  "pages_build_output_dir": "./dist",
  "main": "index.mjs",
  "assets": {
    "binding": "ASSETS",
    "directory": "../public"
  },
  "compatibility_flags": [
    "nodejs_compat",
    "no_nodejs_compat_v2"
  ]
}

Logs

23:32:43.851 | ⛅️ wrangler 4.26.1
23:32:43.851 | ───────────────────
23:32:43.854 | Using redirected Wrangler configuration.
23:32:43.854 | - Configuration being used: ".output/server/wrangler.json"
23:32:43.854 | - Original user's configuration: "wrangler.toml"
23:32:43.854 | - Deploy configuration file: ".wrangler/deploy/config.json"
23:32:43.860 |  
23:32:43.907 | ✘ [ERROR] Processing .output/server/wrangler.json configuration:
23:32:43.907 |  
23:32:43.908 | - The name 'ASSETS' is reserved in Pages projects. Please use a different name for your Assets binding.

Activity

  1. added
    pending triage
    on Jul 30, 2025
  2. changed the title [-]ASSET binding error on deployment when using the cloudflare-module preset[/-] [+]ASSETS binding error on deployment when using the cloudflare-module preset[/+] on Jul 30, 2025
  3. changed the title [-]ASSETS binding error on deployment when using the cloudflare-module preset[/-] [+]ASSETS binding error on deployment when using the cloudflare_module preset[/+] on Jul 30, 2025
  4. thasmo commented on Jul 30, 2025

    @thasmo
    Author

    Wait, never mind. I was accidentally using wrangler pages deploy instead of wrangler deploy. 🤦‍♂️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    pending triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions