Monorepo for wisp.place. A static site hosting service built on top of the AT Protocol. wisp.place
1# Wisp.place 2 3Decentralized static site hosting on the AT Protocol. [https://wisp.place](https://wisp.place) 4 5## What is this? 6 7Host static sites in your AT Protocol repo, served with CDN distribution. Your PDS holds the cryptographically signed manifest and files - the source of truth. Hosting services index and serve them fast. 8 9## Quick Start 10 11```bash 12# Using the web interface 13Visit https://wisp.place and sign in 14 15# Or use the CLI 16cd cli 17cargo build --release 18./target/release/wisp-cli your-handle.bsky.social --path ./my-site --site my-site 19``` 20 21Your site appears at `https://sites.wisp.place/{your-did}/{site-name}` or your custom domain. 22 23## Architecture 24 25- **`/src`** - Main backend (OAuth, site management, custom domains) 26- **`/hosting-service`** - Microservice that serves cached sites from disk 27- **`/cli`** - Rust CLI for direct PDS uploads 28- **`/public`** - React frontend 29 30### How it works 31 321. Sites stored as `place.wisp.fs` records in your AT Protocol repo 332. Files compressed (gzip) and base64-encoded as blobs 343. Hosting service watches firehose, caches sites locally 354. Sites served via custom domains or `*.wisp.place` subdomains 36 37## Development 38 39```bash 40# Backend 41bun install 42bun run src/index.ts 43 44# Hosting service 45cd hosting-service 46npm run start 47 48# CLI 49cd cli 50cargo build 51``` 52 53## Features 54 55### URL Redirects and Rewrites 56 57The hosting service supports Netlify-style `_redirects` files for managing URLs. Place a `_redirects` file in your site root to enable: 58 59- **301/302 Redirects**: Permanent and temporary URL redirects 60- **200 Rewrites**: Serve different content without changing the URL 61- **404 Custom Pages**: Custom error pages for specific paths 62- **Splats & Placeholders**: Dynamic path matching (`/blog/:year/:month/:day`, `/news/*`) 63- **Query Parameter Matching**: Redirect based on URL parameters 64- **Conditional Redirects**: Route by country, language, or cookie presence 65- **Force Redirects**: Override existing files with redirects 66 67Example `_redirects`: 68``` 69# Single-page app routing (React, Vue, etc.) 70/* /index.html 200 71 72# Simple redirects 73/home / 74/old-blog/* /blog/:splat 75 76# API proxy 77/api/* https://api.example.com/:splat 200 78 79# Country-based routing 80/ /us/ 302 Country=us 81/ /uk/ 302 Country=gb 82``` 83 84## Limits 85 86- Max file size: 100MB (PDS limit) 87- Max files: 2000 88 89## Tech Stack 90 91- Backend: Bun + Elysia + PostgreSQL 92- Frontend: React 19 + Tailwind 4 + Radix UI 93- Hosting: Node microservice using Hono 94- CLI: Rust + Jacquard (AT Protocol library) 95- Protocol: AT Protocol OAuth + custom lexicons 96 97## License 98 99MIT 100 101## Links 102 103- [AT Protocol](https://atproto.com) 104- [Jacquard Library](https://tangled.org/@nonbinary.computer/jacquard)