# Web 3.0 Standard (at a high level)

* Ty Everett (<ty@projectbabbage.com>)

## Abstract

This BRC proposes a high-level, rough-draft standard for Web 3.0, defining the integration of blockchain technology, federated overlay networks, digital wallets, and enhanced browser functionalities to enable a decentralized and serverless web experience. This evolves the current web standards to facilitate content and applications that are fully powered by blockchain, allowing users to interact and manage their identities, assets, and cryptographic keys securely and independently.

## Motivation

The current Web 2.0 model relies heavily on centralized servers and client-server architecture. The move to Web 3.0 requires delinking the reliance on central servers by enabling a federated and decentralized infrastructure. This BRC aims to cobble together the necessary standards and protocols to achieve this, focusing on leveraging the previous work in wallet technology, overlays, and decentralized storage to enhance user control, privacy, and interaction on the web.

## Specification

1. **BRC26 Storage Overlay Network:**
   * Facilitates decentralized storage and retrieval of web content.
   * Domain names point to file hashes rather than IP addresses.
   * Integration with DNS via TXT records for domain-to-hash resolution (DNS TXT points to UHRP URL of `index.html`).
   * UHRP URLs replace HTTP URLs for referencing scripts, stylesheets, and images inside HTML.
   * Phase out HTTP URLs in `a`, `img`, `video`, `link`, and `script` tags in favor of UHRP URLs.
2. **BRC56 Wallet Interface:**
   * Provides APIs for digital wallets embedded in browsers.
   * Allows users to manage identities (signing, encrypting, certifying, verifying), assets (in baskets), and cryptographic keys.
   * All identity resolution, permissioning, and certificate management features are supported.
   * Securely interfaces with content and applications via a JavaScript interface on the `window` object.
3. **Peer-to-Peer Communication:**
   * Based on BRC33 (PeerServ) for direct message exchange between users.
   * Expose a JavaScript API for this on the window object.
   * Enhances direct user interaction without intermediary servers.
   * Supports real-time sockets.
4. **Browser Modifications for Web 3.0:**
   * Support for executing local code and interacting with BRC56 Wallet API, and using Overlays for state coordination.
   * Deprecation of Fetch API in favor of authenticated and monetized Fetch alternatives (BRC-31 and BRC-41 wrapped versions on all requests).
   * New JavaScript APIs for overlay service queries (BRC-24), transaction submission (BRC-22), and peer-to-peer communications (BRC-33), all of which support federation across many providers at the browser level.
   * Browsers now host digital wallets. Wallet data to be backed up across many providers.

## Implementation

Incorporate BRC26 hash resolution capabilities, BRC56 wallet interface in the `window` object, and BRC33 message relay between users within web browsers. Replace HTTP and the Fetch API with wrapped versions incorporating BRC-31 and BRC-41 for standardized authentication and monetization of all backend systems.

## References

* \[BRC22: Overlay Transaction Submission]
* \[BRC24: Overlay State Lookups]
* \[BRC26: Storage Overlay Network]
* \[BRC31: User authentication protocol]
* \[BRC33: PeerServ Message Relay]
* \[BRC41: Payments protocol]
* \[BRC56: Wallet Interface]


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://bsv.brc.dev/opinions/0089.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
