Neova고급 SEO 플랫폼

메인 스레드 작업이 2초를 넘음

Neova에서는 Lighthouse 설정이 켜져 있을 때 실행되며, Mac의 Chrome을 사용합니다.

규칙 최종 검토: 2026년 10월 17일 · 가이드 업데이트: 2026년 7월 7일

로드 중에 브라우저 메인 스레드가 2초 넘게 바쁘므로, 페이지가 입력에 늦게 반응합니다. Lighthouse는 4초를 넘으면 실패로 평가합니다. 이 한도를 정한 검색엔진은 없으며, 지켜볼 필드 결과는 200 ms 미만의 INP입니다.

해 볼 수 있는 조치

Lighthouse 세부 분석을 열고 가장 큰 범주부터 줄이세요. 보통 스크립트 평가, 스타일, 레이아웃입니다.

Neova가 플래그를 지정하는 이유

  • 메인 스레드가 바쁜 동안 브라우저는 탭, 클릭, 입력에 반응할 수 없어 페이지가 멈춘 것처럼 느껴집니다.
  • Lighthouse는 2초 넘는 메인 스레드 작업에 플래그를 지정하고 4초를 넘으면 실패로 평가합니다.
  • 이 한도를 정한 검색엔진은 없습니다. Google이 쓰는 필드 지표는 INP이며, 200ms 이하가 좋음입니다.

출처

전체 가이드

이 부분은 현재 영어로만 제공됩니다.

TL;DR

This audit fires when the browser's main thread stays busy for more than four seconds during load, and the culprit is almost always JavaScript being parsed, compiled, and executed. A saturated main thread cannot answer taps or clicks, which is exactly what tanks your Interaction to Next Paint and Total Blocking Time. You fix it by shipping fewer script bytes, breaking bundles into smaller deferred chunks, offloading heavy computation to a web worker, and evicting the third-party junk that hogs the lane.

What This Check Flags

The main thread is a single execution lane, and the browser runs everything through it one job at a time: parsing markup, recalculating styles, laying out boxes, painting pixels, running your JavaScript, and dispatching every click a visitor makes. When one long task grabs that lane and holds it, the tap a user just performed sits in a queue behind unrelated work. Lighthouse breaks the total busy time into buckets so you can see where the seconds went.

Nine times out of ten the dominant bucket is Script Evaluation plus Script Parse/Compile. That is why this audit is really a JavaScript-weight problem wearing a generic name: the engine has to download the script, parse it into an AST, compile it to bytecode, and then run it, all on the same thread that owes the user a response.

A Real Example, and the Fix

Here is the pattern that generates most of the flagged time: a big synchronous chunk of work kicked off during initialization, blocking the thread in one uninterrupted burst.

// Blocks the main thread for hundreds of ms on load
const rows = JSON.parse(hugePayload);       // parse cost
const enriched = rows.map(expensiveTransform); // one long task
renderTable(enriched);

The transform never yields, so the browser cannot slip an event handler in between iterations. The repair is to break the loop into chunks that hand the lane back, or move the whole thing off-thread. Yielding with scheduler.yield() (or a setTimeout(0) fallback) lets a queued click run between batches:

async function processInChunks(rows) {
  const out = [];
  for (let i = 0; i < rows.length; i++) {
    out.push(expensiveTransform(rows[i]));
    if (i % 200 === 0) await scheduler.yield(); // give the thread back
  }
  return out;
}

Genuinely heavy computation (parsing megabyte payloads, image math, crypto) should not chunk on the main thread at all. It belongs in a web worker, where it runs on a separate thread and posts results back when done.

Where the Time Actually Goes

Lighthouse itemizes the main thread by category. Reading this table tells you whether you have a script problem, a rendering problem, or a parsing problem, because the fix for each is different.

Category What Is Happening First Move
Script Evaluation Your JS is executing Ship less, defer, chunk
Script Parse/Compile Engine reading the bundle Code-split, drop dead code
Style & Layout Recalculating geometry Cut layout thrash, batch DOM reads
Rendering / Paint Drawing pixels Simplify effects, promote layers wisely
Parse HTML & CSS Building the DOM/CSSOM Trim markup, split large stylesheets
Garbage Collection Reclaiming memory Reduce allocations in hot loops

How to Detect It

  1. Lighthouse (Chrome DevTools): run the Performance category and open "Minimize main-thread work". It lists each category with its second count under simulated mobile throttling.
  2. PageSpeed Insights: paste the URL to see the same breakdown against real-user field data, so you know whether lab pain matches what visitors feel.
  3. DevTools Performance panel: record a load, then read the flame chart. Long tasks are marked with a red corner; hover one to see whether it is Evaluate Script, Recalculate Style, or Layout.
  4. DevTools Coverage tab: reload with Coverage recording to see what percent of each script is unused. High unused percentages point straight at bundles worth code-splitting.

How to Fix It

Work in this order, because each step shrinks the problem for the next:

  • Send less script. Audit dependencies, drop heavyweight libraries for native APIs or lighter alternatives, and delete unused JavaScript. Fewer bytes means less to parse, compile, and run.
  • Code-split and defer. Break the monolith into route-level chunks and load only what a page needs. Deferring non-critical scripts keeps them from fighting the initial render.
  • Chunk or offload long tasks. Yield inside loops, or push expensive computation to a web worker so the main thread stays free to answer input.
  • Prune third parties. Tag managers, chat widgets, and A/B tools run their own scripts on your thread. Audit each one and cut what does not earn its keep.

For the JavaScript side specifically, our guides on reducing JS execution time and fixing high TBT go deeper on the exact tactics.

FAQ

Is This the Same as Reducing JavaScript Execution Time?

They overlap but are not identical. Execution time is one bucket inside main-thread work; this audit also counts style, layout, paint, parsing, and garbage collection. If your breakdown is dominated by Script Evaluation, the two audits point at the same fix.

Why Does the Report Look Fine on My Laptop but Fails in Lighthouse?

Lighthouse simulates a mid-range phone with CPU throttling. A fast desktop chews through the same script in a fraction of the time, hiding the problem. Trust the throttled numbers, because that is closer to what most visitors experience.

Does Moving Work to a Web Worker Always Help?

It helps when the work is CPU-bound and does not need the DOM, since workers cannot touch the DOM directly. Data crunching, parsing, and math are ideal. Small tasks are not worth the messaging overhead, so measure before you refactor.

How Does This Connect to My Core Web Vitals?

A busy main thread is the mechanical cause behind bad INP and Total Blocking Time. When the thread is stuck on a long task, the handler that should react to a click is blocked, so the page feels dead even though it looks ready.

What Is a "Long Task"?

Any uninterrupted stretch of main-thread work over 50 milliseconds. Everything past that 50 ms threshold counts toward Total Blocking Time, which is why the goal is many short tasks rather than a few long ones.

내 사이트에서 찾아보기

Neova는 크롤링할 때마다 이 점검과 다른 모든 점검을 실행하고, 수정 방법을 팀을 위한 티켓으로 작성합니다.

  • Mac, Windows, Linux용 데스크톱 앱
  • 출처가 함께 있는 696개 점검 전체
  • Search Console과 Analytics 4를 읽기 전용으로 연결
  • Jira, Linear, Asana로 티켓 보내기

Neova 다운로드 Desktop Free 플랜 또는 Solo 14일 무료, 카드 불필요.

성능 점검 전체 · 가이드 · 점검 라이브러리

작성: Neova Labs · 점검 라이브러리로 돌아가기