OpenMagic
v0.31.1 14 providers, 70+ models

AI coding toolbar
for any web app

Run one command and get a floating AI toolbar on your dev server. Select elements, describe changes, approve diffs. It's a reverse proxy, so it works with any framework without plugins or code changes.

$ npx openmagic@latest
Run in your project folder. No account. No IDE extension. No desktop app. Just npx.
View on GitHub npm Package
14
Providers
70+
Models
0
Config files

localhost:3001 -- OpenMagic Toolbar

What it does

The toolbar gives your LLM enough context to actually change your code.

Element Selection

Click any element. OpenMagic grabs its DOM, computed styles, parent layout, siblings, and React component name if available.

Smart Grounding

Reads project files, follows import chains, captures network requests and console output. The LLM sees your actual API responses and errors.

Diff Preview

Changes show up as diffs. You see what gets modified line by line, then approve or reject each one.

Undo

Every file change gets backed up. One click to revert.

Fuzzy File Matching

When the AI names a file, OpenMagic finds it in your project tree with fuzzy matching. No exact paths needed.

Auto-Retry

If the LLM needs more files, OpenMagic reads them and retries automatically. Rate limits and transient failures are retried with backoff.

Network Profiling

Captures fetch/XHR requests, status codes, and timing. This context helps the AI understand what your APIs return and where they fail.

Image Attachments

Drag-drop or paste screenshots into chat. Vision models use them to see what you see.

Keyboard Shortcuts & Session Persistence

Ctrl+Shift+O toggles the toolbar. Chat history and settings survive page reloads via sessionStorage.

Markdown Chat

Markdown rendering in the chat panel with code blocks. Responses are readable, not raw JSON.

Self-verifying edits

Every change is type/lint-checked and runtime-verified after it's applied. If it breaks the build, OpenMagic reverts it and re-prompts with the errors — automatically.

Command palette

Press ⌘K for a fuzzy-searchable palette — select, apply, undo, settings, and more — all from the keyboard.

Framework-aware

Maps the page URL to the right source file for Next.js, Remix / React Router, Nuxt, SvelteKit, SolidStart, Angular, Astro and more — plus a symbol index that finds the component you clicked.


How it works

A reverse proxy sits between your browser and dev server. It injects a script tag. That's the whole trick.

1

Start your dev server, then run OpenMagic in your project folder

Run this in your project folder. OpenMagic detects your dev server, wraps it with a reverse proxy, and injects the toolbar. Your app runs unmodified. Works with anything that serves HTML.

$ npx openmagic@latest
2

Pick a provider and paste your API key

Pick a provider from the dropdown, paste your API key. It's saved to ~/.openmagic/config.json on your machine and only sent to the provider's API.

3

Select elements, describe changes, review diffs

Click an element to give the AI context. Type what you want changed. It proposes edits as diffs. Approve them, and your dev server hot-reloads.


14 providers, 70+ models

API formats, thinking modes, and vision support are pre-configured. You just add your key.

OpenAI
GPT-4o, GPT-4o mini, o1, o1-mini, o3-mini, and more
Vision Thinking
Anthropic
Claude Opus, Sonnet, Haiku (3.5 / 4 families)
Vision Extended Thinking
Google Gemini
Gemini 2.5 Pro, 2.5 Flash, 2.0 Flash, and more
Vision Thinking
xAI (Grok)
Grok 3, Grok 3 Fast, Grok 3 Reasoning
Vision Thinking
DeepSeek
DeepSeek V3, DeepSeek R1
R1 Reasoning
Mistral
Large, Small, Codestral, Devstral, Magistral
Vision
Groq
Llama 4 Scout, Llama 3.3 70B, Qwen, and more
Vision
OpenRouter
200+ models via unified API
Vision Thinking
Ollama
Any local model -- Llama, Mistral, Phi, etc.
Together AI
Llama, Mixtral, CodeLlama, Qwen
Vision
Fireworks
Llama, Mixtral, and fine-tuned models
Vision
Cohere
Command R, Command R+
Perplexity
Sonar Pro, Sonar
AI21
Jamba 1.5 Large, Jamba 1.5 Mini

How OpenMagic compares

Side-by-side with other tools that do something similar.

Feature OpenMagic Stagewise Frontman
Install npx openmagic Electron app Framework middleware
Architecture Reverse proxy IDE extension + browser Build plugin
Framework support Any framework React, Vue, Angular, Svelte Next.js, Astro, Vite
Code changes required None VS Code extension Middleware import
BYOK / No limits Yes / Unlimited Paid tiers Yes / Unlimited
Providers 14 providers Limited OpenAI, Anthropic
Vision / Screenshots Yes Yes No
Thinking models Auto-configured No No
Diff preview Yes No Yes
Undo Yes Via IDE No
IDE required No VS Code No
License MIT Partial Apache 2.0

FAQ

Common questions about OpenMagic.

What is OpenMagic?

OpenMagic is an open-source AI coding toolbar for any web application. Run npx openmagic in your project and a floating AI toolbar is injected into your running app via a single-port reverse proxy. Select any element, describe a change in plain English, review the diff, and OpenMagic edits your actual source code.

How do I install OpenMagic?

Run it instantly with npx openmagic@latest, or install it globally with npm install -g openmagic and run openmagic from any project folder. Requires Node.js 20.19 or newer.

Which AI providers and models does it support?

14 providers and 70+ models, bring your own key: OpenAI, Anthropic Claude, Google Gemini, xAI Grok, DeepSeek, Mistral, Groq, Ollama, OpenRouter and more — plus local CLI agents (Claude Code, Codex, Gemini CLI).

Is it safe to let an AI change my code?

Yes. You review every diff before it is applied, and each change is verified (typecheck/lint plus runtime) after it is written — if it breaks the build it is automatically reverted and the model self-corrects. Undo is durable and one-click.

Which frameworks does it work with?

Next.js, Remix / React Router, Nuxt, SvelteKit, SolidStart, Angular, Astro, Vite, Vue, and plain static sites. It maps the page URL to the right source file and indexes your components.

Is OpenMagic free and open source?

Yes — OpenMagic is MIT licensed and open source. You bring your own API key, so there is no subscription.

Can it review my UI/UX and improve the design?

Yes. One click runs a UX/UI design review that audits the page against your detected design system and proposes brand-consistent fixes. A visual element editor also lets you change CSS, text and attributes with live preview before applying to code.