# I built a Chrome extension that sends any web page to your favorite AI in one click

> Source: <https://dev.to/hudatech/i-built-a-chrome-extension-that-sends-any-web-page-to-your-favorite-ai-in-one-click-42pa>
> Published: 2026-10-23 02:32:47+00:00

Hey DEV! 👋 I'm hudatech, an indie maker from Vietnam. This is my first post here, so I'll start with the thing I've been building: **Page-to-Prompt**.

I read a lot online, and I kept doing the same thing: select some text, copy it, open an AI tab, paste it, type "summarize this" or "explain like I'm five", hit enter. Then repeat for the next article.

It's only a few steps, but it adds up. I wanted the page I'm reading and the AI I'm chatting with to be one click apart.

It's a Chrome extension that works as a bridge between the page you're viewing and your AI chat.

You can open it from the right-click menu, or with `Cmd + Shift + P` (you can change the shortcut on Chrome's extension shortcuts page).

`{{SELECTED_TEXT}}` wherever you want your selection to go, and reuse it anywhere.
**1. Messaging can fail in places you forget about.**

My shortcut handler sends a message from the background script to the content script of the active tab. It worked great on normal pages, but on pages where no content script is running (like the extension's own options page), Chrome throws `Could not establish connection. Receiving end does not exist.` The fix was simple: wrap the call in a `try/catch` and show a friendly message to the user instead of a silent console error.

**2. Never hardcode a keyboard shortcut.**

I first treated `Cmd/Ctrl + Shift + P` as the extension's shortcut. But users can change it on Chrome's extension shortcuts page, so any check that depends on it has to read the *real* command shortcut at runtime.

**3. Raw page text is a bad prompt.**

Sending `document.body.innerText` to an AI means sending menus, ads, and cookie banners too. Running the page through Readability first (and adding a few tweaks on top) made the prompts much cleaner.

**4. Be specific about permissions.**

Broad permissions like access to all sites need a clear justification in the Chrome Web Store listing. Writing down exactly why each permission is needed forced me to double-check that I really needed it.

Page-to-Prompt is available on the [Chrome Web Store](https://chromewebstore.google.com/detail/page-to-prompt/daohfbaahhchiihnfhonbhbbelfnkllm).

I'd love your feedback, especially on which prompts you'd want as defaults and which AI sites I should support next. What do you use AI for while browsing? Tell me in the comments 👇
