Next

How to fix "Module not found" errors with SCSS imports in Turbopack

November 28, 2025

download ready
Thank You
Your submission has been received.
We will be in touch and contact you soon!

Turbopack fails SCSS @import resolution (e.g., Bootstrap) due to stricter aliasing than Webpack; use turbopack.resolveAlias: { '~*': '*' } or explicit loaders for wildcard imports.

Example:-

Code

// next.config.ts
const nextConfig = {
  turbopack: {
    resolveAlias: {
      '~*': '*',  // Fixes @import 'bootstrap/*'
    },
    rules: {
      '*.scss': { loaders: ['sass'] },
    },
  },
};
export default nextConfig;
      
Hire Now!

Need Help with Next Development ?

Work with our skilled next developers to accelerate your project and boost its performance.
**Hire now**Hire Now**Hire Now**Hire now**Hire now

How to fix "Module not found" errors with SCSS imports in Turbopack

Turbopack fails SCSS @import resolution (e.g., Bootstrap) due to stricter aliasing than Webpack; use turbopack.resolveAlias: { '~*': '*' } or explicit loaders for wildcard imports.

Example:-

Code

// next.config.ts
const nextConfig = {
  turbopack: {
    resolveAlias: {
      '~*': '*',  // Fixes @import 'bootstrap/*'
    },
    rules: {
      '*.scss': { loaders: ['sass'] },
    },
  },
};
export default nextConfig;