# Import

> Bring real content onto the canvas — import websites, Figma files and Storybook components, connect a GitHub repo, sync live app screens with a snippet, or just copy and paste.

Source: https://doop.design/docs/import

Bring real content onto the canvas — websites, repos, live app screens, and images.

Good design work starts from real material. Doop has six ways to get it onto the canvas: import any public **website** as editable frames, connect a **GitHub repo** and pull its design system and screens out of the code, turn a **Storybook** into Doop components, paste a **Figma** link and get its frames as editable HTML, drop a **sync snippet** into an app that lives behind a login, or simply **copy & paste**. Everything lands as frames that everyone on the canvas — human or agent — can see and work from.

## Website import

The fastest way to redesign something that already exists. Click **Import** in the canvas's top bar, pick **Website**, paste a URL, and Doop captures the page as a single frame: the real HTML, with every stylesheet inlined, images resolving, and all scripts stripped. What you get is a faithful, fully editable snapshot — not a screenshot.

![Doop's Import a website dialog with a URL filled in, the Import the entire website option and the Import page button](https://doop.design/docs/import/website-capture.png)

Paste a URL and hit Import page — or tick the box to bring in the whole site.

Agents have the same power through the `import_webpage` tool. Give your agent a brief like "redesign acme.com's pricing page" and a well-behaved agent imports the page first, leaves that source frame untouched, and designs in a fresh frame next to it. Imports are de-duplicated — if the same URL is already on the canvas, agents reuse the existing snapshot instead of stacking up copies.

What happens under the hood:

- The page is loaded in a real browser, scrolled to the bottom so lazy-loaded images and reveal animations fire.
- Scripts, iframes, and anything else executable are removed, and a strict content-security policy is injected — imported pages render live but can never run code on your canvas.
- All linked stylesheets are fetched and inlined, so the snapshot keeps looking right on its own.
- The frame is named after the page title, rendered at **1280px wide** at the page's natural height (up to 6000px), and placed to the right of your existing frames.

### Import an entire site

Redesigning more than one page? Tick **import the entire website** in the Import dialog. Doop discovers the site's pages — from its sitemap and by following same-site links — and shows you the list, homepage first, everything selected by default. Uncheck what you don't need and confirm.

![The Choose pages review screen for linear.app listing 100 discovered pages with checkboxes, all selected](https://doop.design/docs/import/choose-pages.png)

Review what discovery found before anything lands on the canvas.

- Up to **100 pages** per import, all from the same domain.
- Pages import a few at a time and land in a tidy **three-column grid** next to your existing frames.
- If some pages fail (a 404 deep in the sitemap, a blocked path), the rest still import — you'll see a count of what made it and what didn't.

### What can't be imported

- **Pages behind a login or bot protection.** If the site answers with a challenge or an error, the import fails cleanly rather than capturing a login wall. For one screen, copy it with the [browser extension](https://doop.design/browser-extension); to keep an app's screens in sync, use the [sync snippet](#sync-snippet-for-live-sites). Both capture from _your_ browser, where you're already signed in.
- **Private and local addresses.** Only public `http(s)` URLs work — `localhost`, internal hostnames, and private IPs are blocked. The sync snippet covers localhost too.
- **Very heavy pages.** Documents over \~3 MB of HTML or with more than 2 MB of CSS are rejected to keep canvases fast.

Imports are limited to 5 per minute per person (agents included).

### Inspect without importing

Sometimes an agent just needs to _look_ at a page — check a competitor's layout, read some copy — without adding anything to the canvas. That's the `view_website` tool: it returns a screenshot and the page's visible text to the agent, and nothing appears on the canvas. Rule of thumb: if the page is source material the whole canvas should see, import it; if it's a quick read-only glance, view it. The two share the same capture pipeline, so a page that can't be imported can't be viewed either.

## GitHub import

Your product's real design system lives in its code — tokens, theme files, tailwind config, the component library. GitHub import connects a repository and pulls that onto the canvas, so every design made there matches what you've actually shipped. It reads the code directly; no deployed site needed.

Connecting a repo can bring in three things:

- **The design system, as a pinned style guide.** Doop distills the repo's theme and token modules, framework config, global styles, and app shell into a canvas guideline — the style rules every agent working on the canvas follows from then on. This is the headline; importing screens is optional.
- **Screens sketched from code.** Pages (Next.js, SvelteKit, Remix, and friends), Storybook stories, and UI components are read from source and rendered as frames — Doop's agent reads the screen's code and the components it imports, builds the frame, then screenshots and corrects its own output.
- **Static HTML, as-is.** Any `.html` files in the repo import directly as sanitized frames.

### Connect a repo

Click **Import** and pick **GitHub repo**. Click **Connect GitHub** to install the Doop GitHub App and pick a repository — private repos work. If you can't install apps, choose _paste a token instead_ and use a fine-grained personal access token. Either way, credentials stay on the server; tokens never appear in frames or reach agents.

![The Connect a GitHub repo step of the Import dialog with the Connect GitHub button and a paste a token instead link](https://doop.design/docs/import/connect-github.png)

Install the Doop app on the repos you choose — access is scoped and revocable on GitHub.

Hit **Analyze** and Doop maps the repo: it detects the framework and lists everything importable — components and stories first, with the full page list behind an optional toggle. Check what you want (design-system extraction is on by default), then import.

The import runs as [Doop Agent](https://doop.design/docs/doop-agent) tasks — the design system first, then screens a couple at a time. Nothing lands until a task finishes, so a failed screen leaves no debris and can be retried from the Agents panel. Imported frames carry a GitHub badge, and connected agents are taught to treat the repo as the source of truth when editing them.

Limits: up to 40 screens per import (the analyzer surfaces up to 300), the same 5-imports-per-minute budget as website import, and each import consumes Doop Agent task allowance.

## Storybook import

If your team keeps its components in Storybook, import them as Doop components. Each story becomes a component with its controls as variants, your theme becomes the canvas's [tokens](https://doop.design/docs/tokens), and your fonts go into the font library. Agents then build screens from your actual Button and Card instead of lookalikes. Import again whenever the Storybook changes and the canvas catches up.

### Import a published Storybook

Click **Import** in the canvas's top bar and pick **Storybook**. Paste the address your Storybook is published at (the page you'd send a teammate, like `https://storybook.example.com`) and click **Find components**. Doop reads the Storybook's story index and lists one entry per component. Filter the list, tick what you need, and click **Import**. There's nothing to connect first.

![Doop's Import from Storybook dialog with a Storybook URL filled in and the Find components button](https://doop.design/docs/import/storybook-url.png)

Paste the address your Storybook is published at.

![The Choose components screen listing 46 components found, with Avatar, Badge, Button and ButtonToggle ticked and an Import 4 components button](https://doop.design/docs/import/storybook-choose-components.png)

One row per component, with its stories file and story count.

The import runs in the background as a **Storybook Import** task, and it keeps going if you close the dialog. When it's done, every component shows what happened to it (created, updated, unchanged, or failed), any notes, and a **% match**: how closely Doop's version matches the story, pixel for pixel. Anything under 90% is flagged so you know which ones to check.

![The Imported result: four components created, Avatar at 100% match, Badge at 90%, Button at 95% and ButtonToggle at 93%, each with notes](https://doop.design/docs/import/storybook-imported.png)

Each component reports how closely it matches its story.

### What Storybook brings over

- **One component per story group.** `Components/Button` becomes _Button_, built from its _Default_, _Primary_, _Basic_ or _Playground_ story (or the first one), and linked to its source file.
- **Controls become props.** Select, radio and boolean controls with 2 to 12 options turn into variant props (`buttonText` becomes `button-text`), and string args that show up as text become text props. Doop renders every option once and keeps the CSS that changes between them, so `<doop-use component="Button" variant="secondary">` looks like it does in Storybook.
- **CSS from the live page.** Styles are read from the rendered story, so Tailwind, CSS modules and CSS-in-JS all work. Hover rules carry over, and a `.dark` theme maps to Doop's dark mode.
- **Theme to tokens.** Custom properties holding colours become colour tokens (with dark values when the Storybook has a dark theme), `--radius*` becomes radius tokens, and `--font-*` becomes font tokens.
- **Fonts to the library.** Every `@font-face` a component uses is copied into the canvas's [font library](https://doop.design/docs/fonts).

### Keep it in sync

Each canvas remembers the Storybooks it imported from. Open **Import → Storybook** again and they're listed under _This canvas imports from_, with a **Sync now** button. A sync re-reads every component you picked: changed ones are updated in place (so every instance on the canvas follows), unchanged ones are skipped, and tokens the import created take their new values. Components and tokens you made yourself are never overwritten, even when the names match; the result tells you which ones it left alone.

### Storybook on localhost or behind a VPN

Doop's servers can only reach a public Storybook. For one running on your machine or inside your network, the Storybook dialog has a ready-made command for a small CLI that renders the stories locally and sends them to your canvas. It needs an agent key from **Settings → Agent keys** and the Playwright or Puppeteer your project already has:

```
curl -fsSL https://doop.design/cli/doop-storybook.mjs -o doop-storybook.mjs
DOOP_KEY=<agent key> node doop-storybook.mjs push http://localhost:6006 \
  --canvas <canvas id> --server https://doop.design
```

- `node doop-storybook.mjs list <url>` prints the components it finds without importing.
- `--only "Components/Button,Components/Card"` or `--match <regex>` import just those components.
- Running `push` again for the same Storybook is a sync, so you can add it to CI after you deploy your Storybook and the canvas stays current on its own.

### Storybook from an agent

Agents get three tools: `list_storybook_components` to see what a Storybook has, `import_storybook` to import all of it or the components you name, and `sync_storybook` to re-sync a Storybook the canvas already imports from. Try _"Import the Button, Input and Card components from https://storybook.example.com onto this canvas"_. Long imports keep running; the agent gets progress back and can check again until it's done.

### Storybook limits

- Up to **60 components** per import, and 24 variant renders per component (a prop past that is left out, and the notes say so).
- **Variants are CSS.** A control that changes a component's markup, not just its classes, keeps its default's markup. Components with more than 400 KB of CSS are skipped.
- Web components (shadow DOM) come over as their light DOM, canvas and WebGL content stays blank, and states that need a `play` function render the way the story leaves them.
- Storybook imports share the 5-imports-per-minute budget with the other importers.

## Figma import

Paste a Figma link into the Import dialog and its frames land on the canvas as real, editable HTML — text stays text, auto layout becomes flexbox, icons stay SVG, and images are copied into Doop. You connect your Figma account once with a personal access token, then import from any canvas. Setup takes about two minutes, start to finish. Figma import and export are **hosted only**: the open-source server has neither, nor the `import_figma` tool.

### 1\. Create a Figma access token

1. In Figma, click your account name in the top-left corner, choose **Settings**, and open the **Security** tab. Scroll to **Personal access tokens** and click **Generate new token**.

![Figma's Settings dialog on the Security tab, showing the Personal access tokens section and the Generate new token link](https://doop.design/docs/import/figma-pat-settings.png)

Settings → Security → Personal access tokens.

1. Name the token (_Doop_ works), pick an expiration, and tick **file\_content:read** under Files — that's the only scope Doop needs. Optionally tick **current\_user:read** too, so Doop can show which Figma account is connected. Then click **Generate token**.

![Figma's Generate new token dialog with the name Doop, a 1 day expiration, and the current_user:read and file_content:read scopes ticked](https://doop.design/docs/import/figma-generate-token.png)

One scope is enough: `file_content:read`. Everything else can stay unticked.

1. Copy the token straight away — it starts with `figd_`, and Figma only shows it once. If you lose it, generate a new one.

![Figma showing the newly created Doop token with a warning to copy it now; the token value is blurred](https://doop.design/docs/import/figma-token-created.png)

Copy it now — this is the only time Figma displays the token.

### 2\. Connect Figma in Doop

Open **Integrations** in Doop's sidebar. The Figma card repeats the steps above; paste the token into the field and click **Connect**. Doop checks the token with Figma before saving it, so a typo or an expired token is caught right there.

![Doop's Integrations page with the Figma card showing three setup steps and a token field with a Connect button](https://doop.design/docs/import/figma-integration-card.png)

Integrations → Figma: paste the `figd_…` token and connect.

The card turns to **connected** and shows the Figma account the token belongs to.

![The Figma card in Doop marked connected, showing the account name and access token, with Replace access token and Disconnect](https://doop.design/docs/import/figma-connected.png)

Connected. _Replace access token_ swaps in a new one when the old one expires.

- **One connection per person, every canvas.** You connect once; it works on any canvas you can edit. Your teammates connect their own Figma accounts.
- **The token stays on the server.** It never appears in frames and never reaches agents — Doop only uses it to read the files you import.
- **Tokens expire; Doop doesn't renew them.** When yours runs out, imports ask you to reconnect — generate a new token and paste it under _Replace access token_. Disconnecting never removes frames you already imported.
- Not connected yet when you open the import? The Figma screen of the Import dialog has the same token field, so you can connect without leaving the canvas.

### 3\. Import frames

Grab a link in Figma — **Share → Copy link**, or just the address bar. A link to the whole file, a page, a section, or a single frame all work; to point at one frame, select it and use **right-click → Copy/Paste as → Copy link to selection**. Then, on your Doop canvas, click **Import** in the top bar and choose **Figma file**.

![Doop's Import into Doop dialog listing sources: Website, Figma file, Photoshop file, Live app, GitHub repo, and Canva design](https://doop.design/docs/import/figma-import-source.png)

Import → Figma file.

Paste the link and click **Fetch frames**. If the link points at one frame, an _Only the linked frame_ checkbox appears — untick it to list every frame in the file instead.

![The Import a Figma file screen with a figma.com/design frame link pasted, the Only the linked frame option ticked, and the Fetch frames button](https://doop.design/docs/import/figma-paste-link.png)

Paste a file, page, section, or frame link.

Nothing lands until you've reviewed it. Doop lists the top-level frames it found, grouped by Figma page, with their sizes. Untick what you don't need (or use _Select page_), then click **Import**.

![The Choose frames review screen listing the Skill Streak frame at 1817×1292, selected, with an Import 1 frame button](https://doop.design/docs/import/figma-choose-frames.png)

Review what Doop found. Up to 25 frames land per import.

The dialog closes and the import carries on in the background as a **Figma Import** task in the Agents panel, with a progress bar. Frames appear on the canvas as they're converted, and the task finishes with a short summary.

![The Agents panel showing a Figma Import task with the status Imported 1 frame from Figma](https://doop.design/docs/import/figma-import-task.png)

The import reports back in the Agents panel.

The frames land laid out the way they are in Figma — same relative positions, pages stacked one below the other — and every layer shows up in the Layers panel, ready to edit, comment on, or hand to an agent.

![A Doop canvas with the imported Skill Streak design — a phone mockup on a purple background — and the Layers panel showing its HTML structure](https://doop.design/docs/import/figma-imported-frames.png)

The Figma frame, now editable HTML on a Doop canvas.

### What comes over

- **Text stays text and auto layout becomes flexbox**, so frames reflow and edit like the rest of the canvas. Vectors and icons come over as SVG.
- **Images are copied into Doop.** Figma's image links expire after a few weeks, so Doop keeps its own copy. If an image can't be copied (it's huge, or Figma won't serve it), the task summary says how many still point at Figma — re-upload those before relying on the frame.
- **Fonts load by name from Google Fonts.** Text set in a face Google Fonts can't serve — a private or licensed font — is converted to outlines so it still looks right, but it's no longer editable as text.
- **Components are flattened** into plain layers, and **prototype links aren't imported** — Doop captures the visual design, not Figma's prototype wiring.
- **Very large frames land as an image.** A frame with thousands of layers (past about 6,000 HTML elements) comes over as Figma's render instead of HTML; the summary tells you when that happened.
- **Access follows your Figma account.** You can import any Figma Design file the connected account can view — drafts, team files, and files shared with you. FigJam boards, Slides, Sites, and Make files aren't supported.
- Limits: 25 frames per import (a file with more than 400 frames lists only the first 400 — link to a single page to see the rest), and Figma imports share the 5-imports-per-minute budget with website and GitHub import.

### Import from an agent

Connected agents get an `import_figma` tool that runs on _your_ Figma connection — the agent never sees or needs a token of its own. Hand your agent a brief like _"Import this Figma design onto my canvas: https://www.figma.com/design/…"_. A link to a frame, page, or section imports directly (up to 8 frames); a link to a whole file returns the frame list so the agent picks what matters. If you haven't connected Figma yet, the agent will ask you to do it on the Integrations page. Agents treat imported frames as source material and design their changes in a separate frame unless you ask them to edit the import.

### Keep pulling from Figma

A Figma file that keeps growing can feed a canvas on a schedule. Add a **Pull** step with a Figma link to an [automation](https://doop.design/docs/automations): each run lists the link's frames and imports only the ones that aren't on the canvas yet — frames you imported by hand are recognised and skipped.

### Send frames back to Figma

It works the other way too. Select frames in Doop, right-click **Export… → Send to Figma…**, and choose **Copy for Figma**. In your Figma file, run the [Doop — Editable import](https://www.figma.com/community/plugin/1685270086415606607) plugin, paste, and click **Add to page**. Frames arrive as native, editable Figma layers — text, vectors, fills, and images — with positions preserved. No token is needed for this direction. It's a snapshot, not a sync: auto layout, variables, and components aren't recreated, and re-sending makes new frames rather than replacing ones you've edited.

## Sync snippet for live sites

The website importer can only reach public pages. The **sync snippet** is the escape hatch for everything else — your product behind SSO, a staging site on a VPN, the app running on `localhost`. It captures screens from your own browser, where you're already signed in.

Click **Import**, pick **Live app**, name the app and create a **sync key**. You get a one-line snippet to drop into your app:

```
<script async src="https://doop.design/doop-sync.js?key=dk_…"></script>
```

![The Sync a live app step showing a sync key named Admin dashboard with its script snippet, the key redacted](https://doop.design/docs/import/sync-key.png)

Name the app, create a key, and paste the one-line snippet into it.

Then just browse your app. Every distinct route you visit becomes a frame on the canvas — sanitized HTML, no scripts, same treatment as a website import — and Doop also records which screens link to which, so agents understand the app's flow, not just its pages.

Built to be safe to run against real apps:

- **Input values are never captured.** Anything you've typed into a form is dropped.
- Mark sensitive elements with `data-doop-mask` to redact them, or `data-doop-sync-ignore` to skip them entirely.
- The sync key is write-only and scoped to a single canvas — it can't read anything back.
- Synced frames **freeze 15 minutes after creation**. They're an import, not a live mirror, and the browser that captured a frozen screen remembers it and stops sending it, reloads included. To re-import a screen, delete its frame, then open that page in your app and run `window.doopSync.capture()` in the browser console.

Snapshots are capped at 2.5 MB per screen, 30 captures per minute per key, and a given page re-syncs at most every 30 seconds while its frame is still fresh.

## Copy & paste

Copy an image anywhere — a screenshot, a photo, a crop from another tool — click the canvas, and hit **⌘V**. Each image becomes its own frame, sized to fit (scaled down to at most 900px on the long side), named after its file, and centered in your current view. Paste several at once and they line up in a row.

Images can be PNG, JPEG, WebP, GIF, or SVG, up to **5 MB** each.

### Attach images to a brief

When you queue work for the [Doop Agent](https://doop.design/docs/doop-agent), the prompt bar's paperclip (or a paste into the prompt) attaches up to **4 images**. Each attachment becomes a reference frame on the canvas, and the agent is instructed to study them before designing — and to treat them as untouchable source material, never something to edit.

### Upload assets from an agent

Connected agents bring their own imagery onto the canvas with the `upload_asset` tool. It returns a permanent public URL the agent can reference from any frame. Three ways in:

- **From a URL** — pass `source_url` and Doop fetches the remote file server-side.
- **From a local file** — pass `local_file: true` and Doop returns a one-time upload URL plus a ready-to-run `curl` command. The file streams straight from the agent's machine to Doop — the bytes never pass through the model. The link is single-use and expires after 15 minutes.
- **Inline** — base64 `data`, as a last resort for tiny files under \~100 KB.

Same rules as pasting: PNG, JPEG, WebP, GIF, or SVG, 5 MB max, with the file type verified from the actual bytes — not the file extension. Uploads are limited to 15 per minute.

## Troubleshooting

- **"This page can't be captured."** The site is behind a login, a bot challenge, or returned an error. Retrying won't help — use the [sync snippet](#sync-snippet-for-live-sites), or paste screenshots instead.
- **The import looks different from the live site.** Snapshots run without JavaScript, so anything the page builds entirely at runtime (client-rendered apps, embedded players) won't appear. The sync snippet captures the rendered result from your browser and handles these cases much better; if the app's code is on GitHub, a repo import sketches those screens from source.
- **GitHub analyze finds nothing.** Screen detection follows framework conventions — Next.js `app/` and `pages/` routes, SvelteKit routes, Remix routes, Storybook stories, and PascalCase components. Repos outside those patterns still get the design-system extraction.
- **"Could not read that Storybook."** Use the Storybook's root address, not a link to one story, and make sure it's public. If it only runs on `localhost` or behind a VPN, use the [CLI](#storybook-on-localhost-or-behind-a-vpn).
- **A Storybook component has a low % match.** Open its notes in the import result. Usually a control changes markup rather than classes, or the story depends on a decorator or a `play` function.
- **"Figma didn't accept that token."** Check you copied the whole `figd_…` value, that it hasn't expired, and that it has the `file_content:read` scope.
- **"Figma no longer accepts this connection — reconnect it."** The token expired or was revoked in Figma. Generate a new one and paste it under _Replace access token_ on the Integrations page.
- **Figma import finds no frames.** Doop imports top-level frames and components (looking inside sections); hidden frames, loose shapes, and groups are skipped. Link to a page or a frame, and make sure the connected Figma account can open the file. FigJam, Slides, Sites, and Make links aren't supported.
- **"Image exceeds the 5 MB limit."** Resize or compress before pasting — frames rarely need more than 900px on the long side anyway.
- **Whole-site discovery missed some pages.** Discovery reads the sitemap and follows same-site links; pages that aren't linked or listed won't be found. Import them individually by URL.

That's the full import surface — pull in the real thing, then design against it. [Connect an agent →](https://doop.design/docs/get-started)
