SnabbSajt · Docs
Site Kit SDK

Convert a plain HTML site

Extract real content from rendered HTML without importing unsafe markup or scripts.

Use the rendered document as evidence, not as the payload. Raw HTML is never stored or executed inside an imported SnabbSajt site.

Convert automatically

npx @snabbsajt/cli@0.2.0 site import html https://example.com -o ./converted
npx @snabbsajt/cli@0.2.0 site import html ./index.html -o ./converted
npx @snabbsajt/cli@0.2.0 site import html ./site.zip -o ./converted

The command writes site.json, evidence.json, validation.json, and both JSON and Markdown import reports. Public URLs are crawled within the same origin and strict page/byte/time limits. Zip files may contain HTML, CSS, and local assets; symlinks, traversal paths, scripts, and executable payloads are rejected or reported inert.

Manual mapping workflow

  1. Open each public HTML page in a browser.
  2. Record navigation, headings, paragraphs, contact details, and meaningful images.
  3. Ignore decorative wrappers, CSS utility classes, scripts, pixels, and hidden elements.
  4. Map visible regions to built-in sections.
  5. Copy used local assets into assets/ and reference their exportId.
  6. Validate and pack the package.
npx site-kit init ./converted-site --template html

Forms and scripts

Do not copy form actions, inline event handlers, script tags, iframes, or tracking snippets. Use contact, lead-form, booking, or another typed section when one matches. Otherwise report the feature as unsupported.

Convert internal links to page or anchor targets. Keep external HTTPS links as external targets. Never copy javascript: URLs.

What converts

  • Visible headings, text, navigation, images, contact details, and safe links.
  • Common layout evidence into native SnabbSajt sections and constrained theme tokens.
  • Supported analytics and booking providers into typed settings or links when the source contains enough facts.

Custom CSS, JavaScript, iframes, animations, checkout behavior, and unknown widgets do not execute. They appear in the import report with a skip, manual action, or native replacement suggestion.

On this page