Show HN: Kage – Shadow any website to a single binary for offline viewing

TL;DR

Kage is a new tool that clones websites into offline, script-free copies by driving a real browser to capture the final page state. It can pack sites into single files or binaries for long-term offline access. This development offers a reliable way to preserve web content and access it without network dependencies.

Kage, a new tool introduced on Hacker News, enables users to clone any website into a fully offline, script-free folder or single executable by using a real headless Chrome browser to capture the final rendered state of pages. This allows for long-term offline browsing and content preservation without reliance on the original website’s scripts or servers.

Kage works by launching a headless Chrome instance to render each webpage fully, wait for all dynamic content to load, then snapshot the DOM before stripping out JavaScript and network calls. The resulting files resemble the live site but contain no active scripts or tracking code, making them safe and reliable for offline use.

The tool supports multiple workflows: cloning entire sites, serving local copies via a lightweight HTTP server, or packing the site into a single ZIM archive or self-running binary. It requires Chrome or Chromium on the host system, but offers a containerized version that bundles Chromium, simplifying setup.

Commands include ‘clone’ for copying sites, ‘serve’ for local browsing, and ‘pack’ for creating single-file archives or executables. Users can specify depth, scope, and other parameters to tailor the clone process, ensuring flexibility for various use cases.

Implications for Content Preservation and Offline Access

Kage offers a practical solution for preserving web content in a stable, script-free format, addressing issues like link rot, site redesigns, and tracking. It is especially relevant for researchers, educators, and archivists seeking reliable offline access to web pages, including complex sites with dynamic content.

By enabling the creation of single-file archives or binaries, Kage simplifies sharing and long-term storage, reducing dependency on persistent internet connections and proprietary formats. Its use of open standards like ZIM aligns with existing offline content projects like Kiwix, expanding options for offline knowledge dissemination.

Amazon

offline website viewer

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Background on Offline Website Cloning and Preservation Tools

Traditional methods of saving web pages, such as browser ‘Save As’ or screen captures, often result in incomplete or non-functional copies over time. Existing tools like HTTrack or Wget can mirror sites but may struggle with dynamic content or scripts that rely on live network calls.

Kage’s approach, leveraging a real browser to capture the fully rendered page before stripping scripts, addresses these limitations by ensuring the offline copy mirrors the final user-visible content. The use of the ZIM format, popularized by projects like Kiwix, provides a standardized way to package large amounts of web content into single, compressed files suitable for offline use.

This development builds on ongoing efforts to improve web archiving, offering a more reliable and flexible method for long-term preservation, especially for sites with complex, dynamic features.

“Kage drives a real browser, waits for the page to settle, then captures a clean, script-free snapshot of the site. It’s about creating reliable offline copies that look and behave like the live site, without any network calls or tracking.”

— Tam Nguyen, creator of Kage

NTI Cloning Kit | NEW! Version 6 of NTI Cloning Software | Best for SSD and HDD Upgrades | Software via Download | SATA-to-USB Adapter Included for 2.5" SSD and HDD

NTI Cloning Kit | NEW! Version 6 of NTI Cloning Software | Best for SSD and HDD Upgrades | Software via Download | SATA-to-USB Adapter Included for 2.5" SSD and HDD

[NEW in V6] Added Windows-mode Cloning, which is more reliable, and supports cloning of BitLocker disks, and RAID…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Limitations and Unanswered Questions about Kage

It is not yet clear how well Kage handles highly interactive or complex sites that rely heavily on JavaScript frameworks. The effectiveness of the stripping process on modern, single-page applications remains to be tested in various scenarios. Additionally, the long-term stability of the generated archives and executables has not been confirmed through extensive use.

Further, the process requires Chrome or Chromium to be installed on the host, which may pose challenges for some users. Details about support for different operating systems, scalability, and handling of sites with frequent updates are still emerging.

Nicholson Crescent 4" Mill Single Cut Bastard File - 08243NN, Standard, 1 Count (Pack of 1)

Nicholson Crescent 4" Mill Single Cut Bastard File – 08243NN, Standard, 1 Count (Pack of 1)

Rectangular shape for sharpening mill or circular saws and draw filing and, with tapered width to ease access…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Upcoming Developments and User Testing Opportunities

Developers plan to improve Kage’s handling of complex, dynamic websites and expand documentation for broader adoption. User feedback will likely shape future features, including better support for large-scale archiving and integration with existing offline content platforms.

Expect updates that address current limitations, along with potential releases of prebuilt binaries for popular operating systems. Community testing and contributions could accelerate refinement and adoption of Kage as a standard tool for offline web preservation.

3500 Pieces 23 Gauge Pin Nails Headless Pins Nails 7 Sizes Assorted Galvanized Brad Nailer 2/5 Inch to 1 Inch for Molding Cabinetry Building Assembly

3500 Pieces 23 Gauge Pin Nails Headless Pins Nails 7 Sizes Assorted Galvanized Brad Nailer 2/5 Inch to 1 Inch for Molding Cabinetry Building Assembly

Large Quantity Package: you will receive 7 sizes of the collated pinner nails, 500 pieces of each size…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Key Questions

Can Kage clone websites with interactive features like forms or videos?

Kage captures the final rendered state of pages after JavaScript has run, but it strips out scripts afterward. It is best suited for static or mostly static content; highly interactive or real-time features may not function in the offline copy.

Does Kage support cloning sites with subdomains or large-scale sites?

Yes, Kage can be configured to include subdomains and set depth limits to control the scope of cloning. It uses robots.txt and sitemap.xml for polite crawling, but large or complex sites may require additional tuning.

Is the resulting archive or executable secure and free of tracking?

Yes, Kage’s process removes all scripts and network calls, making the offline copy safe and free of tracking code. However, users should verify the contents if security is a primary concern.

What formats does Kage support for packing sites?

Kage can create ZIM archives or self-contained executable files that serve the site locally. The ZIM format is open and widely used in offline content projects.

Source: Hacker News


You May Also Like

When Parenting Meets Automation: Toddlers Spend Hours With Chatgpt

When parenting meets automation, toddlers spending hours with ChatGPT reveal new challenges and opportunities that every parent needs to understand.

Hackaday Podcast Ep 373: GPS, Danger In Space, and Robby the Robot

Hackaday Podcast Ep 373 reveals that GPS satellites have broadcast secret messages for 20 years, discusses space dangers, and features Robby the Robot 3D print project.

AI Systems Are Mapping the Seafloor Faster Than Any Human Team Could.

Inefficient manual mapping is being replaced by AI systems that rapidly and precisely chart the seafloor, transforming ocean exploration forever.

Gnutella: A Protocol Outliving the World That Created It

Gnutella, the peer-to-peer file sharing protocol from the early 2000s, continues to function despite mainstream decline, highlighting its resilience and legacy.