Point at your Next.js app, prompt your agent.
Tencil adds one component to your root layout. Press C on your dev site, click an element and say what should change: your agent gets the component and source file, and Fast Refresh shows the result.
npx tencilapp/layout.tsx
import { Tencil } from 'tencil/react'; <body> {children} <Tencil /> </body>One component in your root layout
npx tencilfinds your Next.js app and adds<Tencil />as the last child of<body>. It renders nothing outside development, so the change is safe to commit.pages/_document.tsx
import { Tencil } from 'tencil/react'; <body> <Main /> <NextScript /> <Tencil /> </body>App router and pages router
With the pages router, the component goes into
pages/_documentinstead.initpicks the right file, andnpx tencil init --dry-runshows the change before it writes anything.Your agent gets the source file
Next.js runs React, so Tencil reads the component you clicked and its owners from React, with the file and line each one is written on. The agent starts in the right file instead of searching the repository.
Found from the port
The daemon matches your page to its project through the port
next devlistens on, so several Next.js apps on one machine each get their own pins and agent. In Docker or on a remote dev server, the overlay asks once which project the page belongs to.
Frequently asked questions
Using Tencil with Next.js.
Yes. init adds <Tencil /> to pages/_document for the pages router, and to app/layout.tsx for the app router.
No. <Tencil /> renders nothing outside development, and the overlay itself is a script your machine's daemon serves while you develop.
Yes. Tencil doesn't hook into the bundler for Next.js: the component loads the overlay from the daemon in the browser, whatever builds your app.
More integrations
Tencil works the same everywhere: point at an element, say what should change.
- ViteA Vite plugin for React, Vue, Svelte, TanStack Start and Astro: click any element of your dev site and tell your coding agent what should change.
- ReactIn React apps, Tencil hands your coding agent the component you clicked and the components that render it, each with its file and line. Next.js, Vite, TanStack Start and more.
- Any dev serverNot on Next.js or Vite? Load one script in your development HTML and point at any element of your Rails, Laravel, Django, Phoenix or static site to prompt your coding agent.
- Claude CodeClick any element of your running app and Claude Code makes the change, under your own login. Every pin is a Claude Code session you can resume in a terminal.
- T3 CodeClick any element of your running app and T3 Code makes the change. Every pin is a real T3 Code thread in your project, so you can continue it there.