A creative technical experiment that captivated Hacker News
Tim Wehrle
99 Points on Hacker News
Understanding the constraints of favicon technology
Pushing the boundaries of what's possible
Compress and encode the entire website content into binary data
Embed the encoded data into a valid favicon file structure
The favicon displays normally while containing hidden data
JavaScript decodes and renders the complete website from the favicon
<!-- Favicon contains the entire website -->
<link rel="icon" href="favicon.ico">
<script>
// Extract website from favicon
fetch('/favicon.ico')
.then(r => r.arrayBuffer())
.then(data => {
// Decode and render website
const website = decode(data);
document.body.innerHTML = website;
});
</script>
The favicon acts as both a visual element and a data container for the entire website
Sometimes the most creative solutions hide in the smallest places