Instead of Babel: SWC
Where you call a JavaScript compiler yourself, in a Jest setup, a webpack or Rspack loader or a library build, use SWC. It does the common Babel jobs (TypeScript, JSX, preset-env style targets) in Rust, many times faster. Babel is still maintained. It released version 8 in 2026 and remains the tool for custom syntax plugins.
Both are for compiling modern JavaScript, TypeScript and JSX into code that browsers and runtimes can run.
Why SWC is better
- SWC's site puts it at 20x faster than Babel on a single thread and 70x faster on four cores. Vercel reports its SWC-based Next.js compiler at 17x faster than Babel.
- The SWC CLI is designed as a drop-in replacement for the Babel CLI, and it supports all stage 3 proposals and preset-env, including the bugfix transforms.
- One prebuilt native package replaces a tree of Babel presets and plugins, with binaries for macOS, Linux (including Alpine), Windows and Android.
- It also minifies, which is why Next.js uses it to replace both Babel and Terser.
- It is already the compiler inside Next.js, Parcel and Deno, and Rspack and webpack load it through swc-loader.
When to keep Babel
Keep Babel when you depend on a Babel plugin with no SWC equivalent, such as a macro library, a codemod or an in-house syntax transform. SWC plugins are written in Rust and compiled to WebAssembly, so porting one is real work. Babel also gets transforms for new TC39 proposals early, and Next.js itself falls back to Babel when it finds a Babel config.
Switching
For a standard setup it is a configuration swap. Replace @babel/core and its presets with @swc/core and @swc/cli, translate babel.config into an .swcrc file (parser syntax, targets, React transform), and replace babel-jest with @swc/jest or babel-loader with swc-loader. If you only use Babel through a framework such as Next.js or Vite, you usually only remove the Babel config, and the framework's Rust compiler takes over.
Watch out
SWC's plugin API has had breaking changes, so Rust plugins must be rebuilt against new swc_core versions. Oxc's transformer is newer and benchmarks faster, and Vite has moved to it, so the Rust compiler field has not settled. Babel remains far more widely installed, with 651 million weekly downloads in June 2026.
Also worth a look
- Oxc A Rust toolchain whose transformer, oxc-transform, its own benchmark puts at 4x faster than SWC and 40x faster than Babel; it is the newer choice, and Vite 8 uses it under Rolldown.
More newer, better JavaScript bundlers, compilers and build tools
Sources
- SWC home page
- SWC: Migrating from Babel
- SWC: Implementing a plugin
- Next.js Compiler
- Babel blog
- Oxc: All benchmarks
- Vite: Why Vite
Judged on 2026-11-06. See every javaScript bundlers, compilers and build tools, or all 66 replacements.