vercel/next.js · error · Error

`experimental.cssChunking: "graph"` is only supported with…

Error message

`experimental.cssChunking: "graph"` is only supported with Turbopack. Please remove the option or run Next.js with Turbopack in ${configFileName}.

What it means

Config validation in assignDefaultsAndValidate: graph-mode CSS chunking is implemented only in Turbopack, so enabling experimental.cssChunking: "graph" while running the webpack (or rspack) bundler is rejected. The check only runs during build/dev, since next start does not select a bundler.

Solutions

  1. Remove experimental.cssChunking: "graph", or run with Turbopack (the default).
Defensive patterns

Strategy: validation

When it happens

Trigger: experimental.cssChunking 'graph' mode is used without Turbopack.

Common situations: cssChunking: 'graph' in next.config while running with webpack.


AI-assisted analysis of vercel/next.js@34433fd12e (2026-08-19). Data as JSON: /api/errors/fe71aab4650c719c. Report an issue: GitHub.

Appendix: source

Thrown at packages/next/src/server/config.ts:571

  ) {
    throw new Error(
      `The experimental.allowDevelopmentBuild option requires NODE_ENV to be explicitly set to 'development'.`
    )
  }

  // Validate sassOptions.functions is not used with Turbopack
  if (
    process.env.TURBOPACK &&
    result.sassOptions &&
    'functions' in result.sassOptions
  ) {
    throw new Error(
      `The "sassOptions.functions" option is not supported when using Turbopack. ` +
        `Custom Sass functions are only available with webpack. ` +
        `Please remove the "functions" property from your sassOptions in ${configFileName}.`
    )
  }

  // Validate experimental.cssChunking compatibility with the active bundler. Graph mode is
  // Turbopack-only; strict mode and `false` (single-chunk-per-module) are webpack-only.
  // Only validate during build/dev — `next start` doesn't pick a bundler and would otherwise
  // see `process.env.TURBOPACK` unset and reject a valid `cssChunking: "graph"` config.
  if (
    phase !== PHASE_PRODUCTION_SERVER &&
    phase !== PHASE_INFO &&
    phase !== PHASE_TEST
  ) {
    if (result.experimental.durableUseCacheEntries && !process.env.TURBOPACK) {
      throw new Error(
        `\`experimental.durableUseCacheEntries: true\` is only supported with Turbopack. ` +
          `Please remove the option or run Next.js with Turbopack in ${configFileName}.`
      )
    }

    const cssChunkingValue = result.experimental.cssChunking
    const cssChunkingMode = resolveCssChunkingMode(cssChunkingValue)

View on GitHub (pinned to 34433fd12e)