# What changed in postcss-loader

> 34 changes in postcss-loader 3 to 8 from its official release notes, upgrade guides and advisories: 21 breaking, 1 deprecations, 2 new APIs and options. Each one cited. Sources checked 2026-10-23. HTML: https://unstale.sh/npm/postcss-loader/

To see which of these apply to a repository, run `npx @unstale/cli init` in it.

## postcss-loader 8

### Breaking changes

- The minimum supported Node.js version is now 18.12.0. (8.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v8.0.0)

### Fixes and other changes

- Updates the peer dependency to support @rspack/core v2. (8.2.1) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v8.2.1)

## postcss-loader 7

### Breaking changes

- The minimum supported Node.js version is 14.15.0. (7.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v7.0.0)

## postcss-loader 6

### Breaking changes

- The minimum supported Node.js version is now 12.13.0. (6.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v6.0.0)
- The loader checks PostCSS as a project dependency. (6.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v6.0.0)

## postcss-loader 5

### Breaking changes

- The minimum supported webpack version is now 5. (5.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v5.0.0)

## postcss-loader 4

### Breaking changes

- The config option no longer supports Object values. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The Function notation argument now contains file, mode, and webpackLoaderContext. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The config.ctx option was removed. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The config.path option was removed. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The exec option was renamed to execute. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The ident option is no longer needed for the loader. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The loader now outputs only CSS; use css-loader, file-loader, or raw-loader to inject code into the bundle. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The minimum supported Node.js version is now 10.13. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- postcss is now a peer dependency and must be installed by users. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- PostCSS plugins, syntax, parser, and stringifier options move under postcssOptions. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The default sourceMap value now depends on the compiler.devtool option. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The inline value is no longer supported; use map with inline: true and annotation: false instead. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The minimum supported webpack version is now 4. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The config's loader context was renamed from webpack to webpackLoaderContext. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)

### Deprecations

- Object syntax for the plugin option is soft deprecated; migrate to Array syntax. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)

### New APIs and options

- A message API was added for emitting assets. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)

### Performance

- The loader can reuse an AST from other loaders. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)

### Behavior and default changes

- Config and loader options can be used together; loader options take precedence and plugins are merged. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- postcssOptions can now be a Function. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- Source maps now contain absolute paths in their sources. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)

### Fixes and other changes

- The default export for plugins was fixed. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- Mutations of loader options and config are avoided. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- The map option from loader options and config is now respected. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)
- Compatibility with webpack 5 was fixed. (4.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v4.0.0)

## postcss-loader 3

### Breaking changes

- Requires Node.js version 6.0.0 or newer. (3.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v3.0.0)
- Emits warnings as instances of Error. (3.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v3.0.0)

### New APIs and options

- Adds an AST version to meta.ast. (3.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v3.0.0)

### Fixes and other changes

- Improves ValidationError messages for options. (3.0.0) — [release notes](https://github.com/webpack/postcss-loader/releases/tag/v3.0.0)
