biome: šŸ› high memory usage

VS Code version

1.101.2

Extension version

3.0.3

Biome version

2.0.5

Operating system

  • Windows
  • macOS
  • Linux

Description

over 1500 mb memory usage, even when i don’t use

Image

Steps to reproduce

Use biome as default formatter

Expected behavior

biome shouldn’t use high memory

Does this issue occur when using the CLI directly?

Not sure / Not applicable

Link to a minimal reproduction

No response

Logs

CLI:
  Version:                      2.0.5
  Color support:                true

Platform:
  CPU Architecture:             x86_64
  OS:                           windows

Environment:
  BIOME_LOG_PATH:               unset
  BIOME_LOG_PREFIX_NAME:        unset
  BIOME_CONFIG_PATH:            unset
  BIOME_THREADS:                unset
  NO_COLOR:                     unset
  TERM:                         unset
  JS_RUNTIME_VERSION:           v22.16.0
  JS_RUNTIME_NAME:              node
  NODE_PACKAGE_MANAGER:         pnpm/10.12.1

Biome Configuration:
  Status:                       Loaded successfully
  Path:                         biome.json
  Formatter enabled:            true
  Linter enabled:               true
  Assist enabled:               true
  VCS enabled:                  true

Workspace:
  Open Documents:               0

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Reactions: 15
  • Comments: 21 (5 by maintainers)

Most upvoted comments

I’m seeing the same thing on mac

Image

Title: Biome uses high CPU and memory after running pnpm run dev

Environment:

  • OS: Windows 11
  • Editor: VS Code
  • Tech stack: Next.js 15 (App Router), TypeScript, Tailwind CSS
  • Package manager: pnpm
  • Biome installed: locally

Issue: When I open VS Code (cold start), Biome uses around 18 MB RAM with no dev server running. After running pnpm run dev, memory usage quickly jumps to 500–1000 MB, and when I open the browser to view the app, CPU usage goes to 100% and RAM usage increases to 8+ GB.

What I tried:

  • I cleared the biome.json config to just {} — no effect.
  • When I enable linter.domains.project, even without running the dev server, Biome starts using 100% CPU and high RAM just from VS Code being open.
  • When I enable linter.domains.project, Biome immediately starts using 100% CPU and high RAM, even if the dev server is not running. Just having VS Code open causes the load.

Expected behavior: Biome should work efficiently and not cause heavy CPU or RAM usage during normal development. It should not slow down the system just because a project is open or the dev server is running.

Possible cause: Biome might be scanning or analyzing too many files when the project is active.

@ematipico I haven’t observed high memory usage, but rather a hanging process and high cpu usage. The preview release fixes it for me. Not sure if https://github.com/biomejs/biome/issues/6792 is related though.

Can someone test the following release? Let me know if it fixes the problem, please?

npm i https://pkg.pr.new/biomejs/biome/@biomejs/biome@a6874f9

Fixes the problem

Just for reference, I’m using Linux (Ubuntu) and the same happens after I updated to biome 2.x. So it’s probably not OS specific. We’re using yarn. Just by having VSCode open, biome keeps consuming more and more RAM (40GB+) until there’s no free RAM anymore, slowing down the system.

Setting linter.domains.project to none didn’t seem to have any effect, RAM usage still kept growing rapidly.

The memory map isn’t particular useful either, it just has a single very large section:

Image

I’m using an NX monorepo. After disabling noImportCycles, memory usage dropped from 1GB to under 100MB, so I’ve kept it off for now. This rule seems to need performance improvements.

The issue is that when I open a project, Biome scans through the entire directory, including node_modules. Therefore, I need to provide the following configuration in all projects, even those where I’m not using Biome:

{
    ā€œfilesā€: {
        ā€œincludesā€: [ā€œsrc/**/*.{ts,tsx,js,jsx,json,css,html}ā€],
        ā€œignoreUnknownā€: true
    }
}

Can someone test the following release? Let me know if it fixes the problem, please?

 npm i https://pkg.pr.new/biomejs/biome/@biomejs/biome@a6874f9

in my case vscode biome is leaking memory and running with high CPU

Image Image