Vibe Modify is a Chrome extension that lets you customize websites with natural language.
The flow is:
- Open a website.
- Describe the change you want.
- The extension sends the rendered HTML plus your request to the selected AI provider.
- The provider returns JavaScript.
- The extension runs that JavaScript on the page and saves it for matching URLs.
The extension currently supports:
- Anthropic
- OpenAI
- User-provided API keys stored locally in the extension
There is no backend yet.
- Chrome Extension MV3
- React 18
- TypeScript
strict - Tailwind 4
- Webpack
- Dexie
npm install
npm run dev
npm run buildThen load the unpacked extension in Chrome:
- Open
chrome://extensions/ - Turn on Developer mode
- Click Load unpacked
- Select this project's
dist/directory
If you edit source files while npm run dev is running, reload the extension in Chrome.
When a user opens the extension for the first time, they see onboarding instead of the normal prompt UI.
They save their own Anthropic or OpenAI API key. Shared invite-code keys are intentionally disabled because secrets embedded in a browser extension can be extracted from the bundle.
After successful setup, the extension stores the selected provider and routes the user into the main customization UI.
Users can configure their own key directly inside the popup.
Supported providers:
- Anthropic
- OpenAI
Provider selection is explicit. Vibe Modify does not silently fall back to another provider during generation. If the selected provider has no key configured, the UI shows an error and points the user back to Settings.
The popup includes a Settings screen where the user can:
- Change the selected provider
- Save or replace an Anthropic key
- Save or replace an OpenAI key
- Remove stored keys
- Test the selected connection
- Toggle automatic reapply of saved customizations
Stored keys are masked in the UI and are never shown in full after saving.
Default models are centralized in:
src/shared/aiModels.jsonCurrent defaults:
- Anthropic:
claude-sonnet-4-6 - OpenAI:
gpt-4.1-mini
Optional build-time model overrides can be set in .env:
ANTHROPIC_MODEL=claude-sonnet-4-6
OPENAI_MODEL=gpt-4.1-mini.env is not used for API keys anymore.
The popup uses the official PostHog browser SDK build that does not load external code, which is compatible with Chrome Extension MV3. Configure the same PostHog project used by the landing page:
POSTHOG_PROJECT_TOKEN=phc_...
POSTHOG_HOST=https://us.i.posthog.com
LANDING_PAGE_ORIGIN=https://your-vibe-modify-domain.exampleThe project token is public. Do not put a PostHog personal API key in the extension. LANDING_PAGE_ORIGIN must exactly match the deployed checkout origin, without a trailing slash; it lets the paid success page hand off the anonymous distinct id and campaign labels to the extension.
Tracked events are install_or_signup_started, install_or_signup_completed, first_modification_started, first_modification_completed, and return_visit. Analytics never includes prompts, page URLs, page HTML, generated scripts, provider API keys, or email addresses.
Two storage layers are used:
chrome.storage.local- AI provider selection
- API keys
- onboarding completion
- automatic reapply toggle
- IndexedDB via Dexie
- learned URL templates
- saved generated scripts
This beta intentionally stores API credentials locally inside the extension.
That is acceptable only for trusted private testing.
If shared credits or invite codes are added later, generation and redemption must move behind a backend. Never embed a shared provider key in the extension bundle.
src/
manifest.json
Popup.tsx
background.ts
content.ts
styles.css
popup/
PromptForm.tsx
HistoryList.tsx
OnboardingSetup.tsx
ProviderSelector.tsx
SettingsPanel.tsx
background/
aiFactory.ts
aiProvider.ts
anthropicProvider.ts
openaiProvider.ts
injection.ts
pageContent.ts
lib/
database.ts
htmlStripper.ts
promptBuilder.ts
settings.ts
sandbox.ts
urlTemplate.ts
shared/
ai.ts
aiModels.jsonchrome.userScriptsis still required for CSP-resistant script execution.- The sandbox shim still blocks cookies, storage, and iframe creation inside USER_SCRIPT world, but it does not block all network egress.
There are no automated tests yet.
Before shipping changes, run:
npm run typecheck
npm run lint
npm run buildManual smoke test:
- Build and load
dist/ - Open the extension and complete onboarding with your own key
- Open a normal
http(s)page - Apply a prompt such as
Hide the navigation bar - Confirm the change applies immediately
- Reload the page and confirm it reapplies
- Open Settings and verify provider status, masked keys, and Test Connection