Fork-and-go Chrome Extension boilerplate built with React, TypeScript, Tailwind CSS, and Vite. It targets Manifest V3 and includes common extension surfaces out of the box: Popup, Side Panel, Options, and DevTools, plus background and content scripts.
- MV3 service worker background
- React + TypeScript UI surfaces
- Tailwind CSS styling
- Vite-based multi-entry build with HTML relocation
- Ready-to-use Popup, Side Panel, Options, and DevTools pages
- Background and Content script templates
- Popup
- Side Panel
- Options Page
- DevTools Panel (via devtools-page loader)
- Background Service Worker
- Content Script
.
├─ manifest.json
├─ public/
│ └─ icons/
└─ src/
├─ app/
│ ├─ popup/
│ ├─ sidepanel/
│ ├─ options/
│ ├─ devtools/
│ └─ devtools-page/
├─ scripts/
│ ├─ background/
│ └─ content/
└─ shared/
├─ components/
├─ hooks/
├─ styles/
└─ utils/npm run dev: start Vite dev servernpm run build: type-check + build + copy manifest into distnpm run copy-manifest: copymanifest.jsontodist/manifest.jsonnpm run lint: run ESLintnpm run preview: preview production build
vite-plugin-chrome-extension.tsmoves generated HTML files todist/root.manifest.jsonremains in repo root and is copied intodist/bycopy-manifest.
npm installnpm run devnpm run buildThe production build outputs to dist/.
- Build the extension:
npm run build
- Open Chrome and go to Extensions.
- Enable Developer mode.
- Click Load unpacked.
- Select the
dist/folder.
- Popup UI:
src/app/popup/ - Side Panel UI:
src/app/sidepanel/ - Options UI:
src/app/options/ - DevTools UI:
src/app/devtools/ - DevTools loader:
src/app/devtools-page/ - Background (service worker):
src/scripts/background/ - Content script:
src/scripts/content/ - Shared styles/components/utils:
src/shared/
The default manifest includes:
tabs,storage,sidePanelhost_permissionsfor<all_urls>- A content script that runs on all pages
Update manifest.json to reduce permissions and narrow host matching for your use case.
- Update
manifest.json(name, description, version, permissions, entry points). - Replace icons under
public/icons/and reference them in the manifest. - Remove any surface you don’t need (and delete the manifest entry).
- Popup, Side Panel, Options, and DevTools are separate React entry points.
- Background and Content scripts are built as standalone MV3 scripts.