# QwikDev/partytown

Relocate resource intensive third-party scripts off of the main thread and into a web worker. 🎉

Repository: https://github.com/QwikDev/partytown
Canonical: https://ross.abutalabs.com/products/partytown
Homepage: https://partytown.qwik.dev
Language: TypeScript
License: MIT
License Family: permissive
Topics: webworker, 3rd-party, 3rdparty, web-worker, performance, analytics, core-web-vitals, lighthouse, lighthouse-score, javascript, dom
Last push: 2026-08-25T16:02:58+00:00

## Health v2 (maintenance only)
Score: 95/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 99, release rhythm 87, longevity 100
- inputs: {"age_days": 1839, "days_push": 8, "days_rel": 8, "gap_med": 56, "n_releases_24m": 8}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 13765, forks 448 (observed 2026-08-28T04:11:04.750449+00:00)

## What it is
Partytown is a lazy-loaded JavaScript library that relocates resource-intensive third-party scripts (analytics, ads, trackers) off the main thread and into a web worker. It works with any HTML page and offers integrations for frameworks like React, Next.js, Qwik, Angular, and SvelteKit.

## Use cases
- run Google Tag Manager or Facebook Pixel without blocking the main thread
- improve Lighthouse scores and Core Web Vitals affected by third-party scripts
- sandbox third-party scripts and control their access to main thread APIs
- reduce layout thrashing from analytics and ad scripts
- speed up page load when embedding ads, A/B testing, or tracking scripts

## When to choose
- your site loads third-party scripts like analytics, ads, or trackers that hurt main-thread performance
- you want to keep the main thread dedicated to your own application code
- you need to isolate or sandbox third-party script access to DOM APIs

## When to avoid
- your third-party scripts require synchronous main-thread DOM access or frequently manipulate the DOM
- you cannot thoroughly test scripts, since some may silently fail in the web worker
- you need guaranteed compatibility in every scenario, as Partytown is still in beta

## Facets
- artifact type: library
- maturity: active
- function: web-framework, developer-tools, security
- domain: web-development, frontend, performance, analytics
- platform: browser, cross-platform
- tags: web-worker, third-party-scripts, core-web-vitals, lighthouse, main-thread, sandboxing, dom-proxying, web-server

## Member repositories
- QwikDev/partytown (main) score 95

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:11:04.750449+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:13:03.272316+00:00, confidence not recorded.
  - readme: https://github.com/QwikDev/partytown (fetched 2026-08-28T04:11:04.750449+00:00, sha 810c99a1e181)
  - homepage: https://partytown.qwik.dev (fetched 2026-08-29T08:07:44.446680+00:00, sha 956ccac74e09)
  - site_page: https://partytown.qwik.dev/getting-started (fetched 2026-08-29T08:07:44.458093+00:00, sha 60d055d7203c)
  - site_page: https://qwik.dev/docs/integrations/partytown (fetched 2026-08-29T08:07:44.461525+00:00, sha 2f7a8a766b8f)
  - site_page: https://partytown.qwik.dev/faq (fetched 2026-08-29T08:07:44.456008+00:00, sha 40b59895e46c)
  - site_page: https://partytown.qwik.dev/integrations (fetched 2026-08-29T08:07:44.459860+00:00, sha a4a2a7fb0b06)
- Data as of 2026-08-30T08:39:29.467469+00:00.
