Prompt API (LanguageModel, Gemini Nano)
Runs a local language model in Chrome and lets a page prompt it.
In one line
Can run a small AI model on your device with text you give the page
Runs a local language model in Chrome and lets a page prompt it.
Page text and the person's input stay on the device. The page can summarise, classify or chat without sending data to a server.
What it can and can't do
What the user does: You tap a button like Summarize, Reply or Ask AI on the page
It can
- Send the page text or your message to a local AI model
- Get summaries, labels, smart replies or chat answers without a server
- Download the model the first time, which can take a while
It cannot
- Start before a click or tap
- Send your text to a server for this feature
- Work in Firefox, Safari or on Chrome for Android
- Run on computers without enough space and a capable chip
How it differs between platforms: Chrome on desktop supports it; Edge is in testing. Firefox, Safari and all phones do not.
Browser support
| Browser | Status | First version | Released | Note |
|---|---|---|---|---|
| Chrome | Supported | 148 | 2026-05-05 | None |
| Edge | Behind a flag | 138 | Not listed | Behind flag |
| Firefox | Not supported | Not available | Not listed | None |
| Safari | Not supported | Not available | Not listed | None |
| Safari on iPhone | Not supported | Not available | Not listed | No iOS |
| Chrome on Android | Not supported | Not available | Not listed | No Android |
| Samsung Internet | Not supported | Not available | Not listed | None |
How a site asks for it
| API | await LanguageModel.availability(); const s = await LanguageModel.create({temperature,topK,initialPrompts,expectedInputs}); s.prompt(text), promptStreaming() |
| Permissions policy | language-model |
| Browser compat keys | api.LanguageModel |
| How access is granted | gesture |
| What the user sees | Download progress on first use; user activation needed before create() |
| Needs a secure context (HTTPS) | Yes |
| Needs a user gesture | Yes |
| How long it lasts | Model stays on disk until eviction (below 10 GB free) |
| How to take it back | chrome://on-device-internals |
| Inside an iframe | Same as top level; cross-origin iframes need a permissions policy where listed |
Typical flow
- Call the API
- Browser applies its access rules
- Page receives the result
Data you get
What comes back: Runs a local language model in Chrome and lets a page prompt it.
Shape: object
How often: on demand
| Field | Type | Unit | Range | Precision |
|---|---|---|---|---|
availability | enum | None | unavailable, downloadable, downloading, available | Not listed |
contextWindow | integer | tokens | model defined, reported at runtime | contextUsage and contextoverflow event |
languages | list | None | en, ja, es, de, fr | input and output |
input types | list | None | text, image (several element types), audio (AudioBuffer, ArrayBuffer, Blob) | output is text only |
temperature / topK | float | None | extensions: default topK 3, max 128; default temp 1, max 2 | must be set together |
Technical limits
- Hardware: Windows 10 or 11, macOS 13+, Linux, or ChromeOS Plus; 22 GB free disk; GPU over 4 GB VRAM or CPU with 16 GB RAM and 4 cores
- Not on Android, iOS or non Plus ChromeOS
- Model removed if free space drops below 10 GB
- Not available in Web Workers; cross origin iframes need allow="language-model"
- Output can be constrained to a regex or JSON schema
The story
What it is
A page can talk to a small AI chat model built into Chrome, running on your own computer.
For you
A site can offer an AI helper that works without sending your words to a server. You may wait for a model download the first time. It starts after you click or tap.
For makers
Makers get a free, private AI that works offline and costs no cloud fees. It lets them build smart features at scale. The model is small, so results are simpler than big cloud AI.
Where you see it
| Type | Example | Apps |
|---|---|---|
| games | A browser role play game uses the local model to make non player characters talk back, with no server bill per player. | None named |
| productivity | A web notes app answers questions about your own notes, with the notes never leaving your device. | Notion |
| education | A study site quizzes a student on their own text offline on a school laptop. | None named |
| messaging | A chat app suggests replies from the conversation on device. | None named |
| shopping | A store assistant helps pick a product from specs in the page, with no external AI service. | None named |
| creative | A web design tool suggests names and text for a layout on the device. | Figma |
| accessibility | A page explains hard terms in simpler words for a reader, with nothing sent out. | None named |
| developer | A developer builds a form that extracts details from free text on the device. | None named |
Risks
- Large download
- Simple answers, can be wrong
What the platform says
- Google Chrome: Prompt API. Lets web pages send prompts to Gemini Nano in Chrome, so AI features run locally, privately and offline.
Good uses and abuse
Legitimate uses
- Local summarisation
- Smart replies
- Offline helpers
Known abuse
- Prompt fingerprinting by availability state
- Heavy downloads
Scores
| Score | Value | Meaning |
|---|---|---|
| Sensitivity | 2 of 5 | How revealing the data is |
| Utility | 4 of 5 | How useful it is to honest apps |
| Friction | 2 of 5 | How much the user has to do |
| Fingerprint bits | Not rated | Rough identifying entropy, when known |
History
- 2024, Chrome 138: Prompt API stable for extensions
- 2025, Edge 138: Edge behind a flag
- 2026-05, Chrome 148: Prompt API stable on the web (per BCD; page text inconsistent)
Sources
How well checked: Checked against real behavior.