Replaces your new tab page with a page showing the extension's environment values.
Runs on Chrome, Edge, Firefox · Manifest V3 · Surfaces: new tab, background service worker · Styling: CSS · Level: beginner
Create this project
npx extension@latest create my-newtab-env --template newtab-env
cd my-newtab-env
npm install
npm run dev
With an AI agent: ask it to "Create an extension from the newtab-env template." With the extension.dev MCP it runs extension_create. Setup: https://docs.extension.dev/tools/mcp/clients
What it is for
Inject build-time configuration without leaking secrets
Switch behavior per browser, mode, or deployment target
Reference for safe env-var usage across JS, JSON, and HTML
First steps
Copy .env.example to .env and edit the values
Run npm run dev to launch the extension
Open a new tab and the page reads injected EXTENSION_PUBLIC_* values