---
title: Fix Vite 8's build.rollupOptions Deprecation
description: Fix the build.rollupOptions deprecation warning in Vite 8. Rename to build.rolldownOptions before the old key is removed.
date: 2026-08-05T00:00:00.000Z
category: guides-fixes
tags: vite, rolldown, config, bug-fix
---

## Quick Answer

Vite 8 renames `build.rollupOptions` to `build.rolldownOptions` (and `worker.rollupOptions` to `worker.rolldownOptions`), since Rolldown replaces Rollup as the production bundler. The old key still works today, deprecated and auto-mapped, but any project customizing `manualChunks`, `external`, or `output` under it now prints a deprecation warning on every build. Rename the key to silence it.

## Why the key was renamed

Rolldown, not Rollup, is Vite 8's production bundler. [Vite's migration guide](https://vite.dev/guide/migration) lists the rename directly under "Deprecated Options": `build.rollupOptions` → `build.rolldownOptions`, alongside the same rename for `worker.rollupOptions` → `worker.rolldownOptions`.

`build.rollupOptions` is one of the single most commonly customized Vite options. It's where `manualChunks`, `external`, and custom `output` naming patterns live for most real projects. That popularity is exactly why this deprecation is loud: any project with a nontrivial build config sees the warning on every single build the moment it upgrades to Vite 8, even though nothing is actually broken yet.

## Fix it: rename the key

### Before: the deprecated key

```js title="vite.config.ts"
export default defineConfig({
  build: {
    rollupOptions: {
      output: {
        manualChunks(id) {
          if (id.includes("node_modules")) return "vendor";
        },
      },
    },
  },
});
```

### After: the same config under the new key

```js title="vite.config.ts"
export default defineConfig({
  build: {
    rolldownOptions: {
      output: {
        manualChunks(id) {
          if (id.includes("node_modules")) return "vendor";
        },
      },
    },
  },
});
```

Nothing inside the object changes. If your project also customizes `worker.rollupOptions` for a web worker build, rename that key the same way.

<Callout type="tip" title="Check manualChunks while you're in there">
  If your `manualChunks` uses the older object-map shorthand instead of a
  function, the rename alone won't fix your build. Rolldown only supports the
  function form. See [Fix Vite 8 manualChunks Object Form
  Removed](/guides-fixes/fix-vite-8-manualchunks-object-form-removed/) for that
  separate, sharper break.
</Callout>

## Confirmed version range

Documented in Vite's own current migration guide as an intentional Vite 8 rename, auto-mapped for backward compatibility today. This site's own `astro.config.mjs` doesn't customize `build.rollupOptions` at all, so this specific deprecation warning doesn't fire on this repo's own build. The rename still applies to any project that does customize it, which is common enough to be worth fixing proactively rather than waiting for a future major version to remove the old key outright. Browse more posts like this in the [Guides & Fixes](/guides-fixes) archive.
