✦ v1.3.0 — Browser-native P2P

The backend
that isn't a backend

A distributed filesystem that lives entirely in the browser. No servers. No databases. Just peers sharing the same address.

SharedProtocol://5221_loading… YOUR NODE

One address.
Every tab.

SharedProtocol gives every browser a persistent identity and a virtual filesystem. Write a file on Tab 1 and it appears on Tab 2 — instantly, without touching a server. The mesh IS the storage.

0
servers
peers
3h
peer TTL

Everything you'd
expect from a real FS

🪪
Persistent identity
Each peer gets a unique address stored in OPFS. It survives refreshes, tab closes, and restarts.
📂
Full VFS
newfile, newfolder, cat, lsfolder, cp, cd, del — a real Unix-style filesystem in the browser.
📡
Live P2P sync
BroadcastChannel for same-origin tabs. WebRTC DataChannels for cross-origin peers. Always in sync.
💾
Big file storage
Files over 1MB go to SPbig — an OPFS-backed large file layer with automatic quota management.
🔒
Path permissions
Restrict and expose paths on any peer. Protected system namespaces enforce clean boundaries.
♻️
Peer TTL
Inactive peers are evicted after 3 hours, freeing their ID for new nodes to claim.

Simple by design.
Powerful by nature.

1
Claim your address
On first load, SP picks a random peer index and broadcasts a claim attempt. No conflicts? You own SharedProtocol://5221_<index> permanently.
2
Write to the shared tree
Every file and folder you create lands in the shared namespace. The VFS tree is persisted to OPFS so it survives refreshes.
3
Sync propagates instantly
A BroadcastChannel fires on every write. Other tabs receive the op and update their local tree immediately — no polling, no delay.
4
WebRTC for cross-origin
When a new peer is discovered via SYNC_DATA, SP initiates a WebRTC handshake. SDP is exchanged through the VFS itself — no signaling server needed.

Drop in a script.
You're done.

Include the script and sp is globally available. Call sp.ready() to wait for identity claim, then use the filesystem.

example.js
// Drop in the script // <script src="https://sharedpro.pages.dev/sharedprotocol.js"></script> await sp.ready(); // Your address in the mesh console.log(sp.address); // → SharedProtocol://5221_8392847 // Write files and folders await sp.newfolder("/notes"); await sp.newfile("/notes/hello.txt", "Hello, mesh!"); // Read them back — on any tab sp.cat("/notes/hello.txt"); // "Hello, mesh!" sp.lsfolder("/"); // [{ name: "notes", type: "folder" }] // Large files go to SPbig (OPFS-backed) await sp.bigWrite("image.png", blob); const file = await sp.bigRead("image.png");

Just so we're
clear.

SharedProtocol is a filesystem protocol. What you put in it is your responsibility, not ours.

⚖️
--fetch: is your fetch
When you use --fetch: on a file, you are making that HTTP request. SharedProtocol does not fetch anything on your behalf. The developer of SP is not responsible for what URLs you choose to fetch, cache, or distribute through the mesh.
📡
The mesh is yours
The P2P mesh syncs whatever is in your VFS to peers you connect with. SP does not control, moderate, or have visibility into what any peer stores or shares. Each peer is independently responsible for their own node.
🗂️
OPFS is your storage
Files persist in your browser's Origin Private File System. That's your device, your browser, your data. The SP developer has no access to it, no copy of it, and no ability to delete it on your behalf.
🚫
Don't be that person
SharedProtocol was built for building apps without backends — not for piracy, not for distributing copyrighted content, not for anything illegal. The tool is neutral. Use it responsibly. --stayforever is not a license.

Ready to kill
your backend?

One script tag. No accounts, no API keys, no servers. Just pure peer-to-peer storage.

that's literally it
<script src="sharedprotocol.js"></script>