Extension foundations

Create the Manifest V3 file

Declare the extension identity, version, popup action, permissions, and packaged files in a minimal manifest.json.

8 minute lesson

~~~

Every extension has a root manifest.json. It tells the browser what the package contains and which capabilities it requests.

Manifest V3 is the current Chrome extensions platform. Begin with required metadata and the action popup. Add permissions only when a later lesson implements the feature that uses them.

The manifest is both configuration and a trust declaration. API permissions such as storage and scripting grant extension capabilities. Host permissions grant access to matching origins and may produce user warnings. activeTab is different: it grants temporary host access after a qualifying user gesture rather than persistent access at installation.

{
  "manifest_version": 3,
  "name": "Page Notes",
  "version": "1.0.0",
  "description": "Save a note for the current page",
  "action": { "default_popup": "popup.html" },
  "permissions": ["storage", "activeTab", "scripting"]
}

The example declares the end-state permissions so you can see them together. In the project, begin with only the popup, then add each permission with the feature that consumes it. This makes unused authority obvious in code review. Keep the version compatible with Chrome’s one-to-four-part numeric format and increment it for every published package.

Create a clean project folder with the manifest and an empty popup page. Load it once with no permissions, then add storage, activeTab, and scripting one at a time. For each addition, write down the exact API and user-facing behavior it enables.

Lesson completed

Take this course offline

Get every free book and course as PDF and EPUB files.

Get the download library →