> For the complete documentation index, see [llms.txt](https://hub.bsvblockchain.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hub.bsvblockchain.org/wiki/standards-protocols-and-tools/building-on-bitcoin/application-layer-protocol.md).

# Application layer protocol

1. Introduction Application layer protocols in Bitcoin are rule sets defined and stored in transactions as arbitrary data. Various protocols have been implemented by application developers to store websites, social media posts, images, identity and other types of data since the OP\_RETURN push data limit was increased to 100KB.
2. Practical example With the data carrier size of an output expanded to 100KB, we can store various types of data by creating a False Return output in a Bitcoin transaction. Bitcom is a proposal of a protocol, for defining protocols. Bitcom proposes to store a Bitcoin address as the prefix, ensuring uniqueness and a namespace. A heavily used protocol was the [B://](https://github.com/unwriter/B) protocol created by developer \_unwriter. This protocol defines how files can be stored on-chain, leveraging the Bitcom construct also defined by \_unwriter. For example, to store a photo of a duck, we use the protocol prefix for B:\\: 19HxigV4QyBv3tHpQVcUEQyq1pzZVdoAut Followed by the different fields B:\ defines as additional push data:

```bash
[Image Buffer]
image/png
binary
duck.png
```

1. Unlimited transaction size These constructs were created to work with a 100KB transaction size, but with the Genesis upgrade much larger data can be written in a single transaction. Additionally, the OP\_PUSHDATA opcodes are able to be used properly in script eliminating the reliance on using OP\_RETURN as the sole means of pushing data into transactions.
2. Widely used protocols

* Metanet Protocol - Defines a directed graph structure that stores data on the Bitcoin ledger where it can easily be queried and referenced by other applications.
* [Tokenized Protocol](https://www.tokenized.com) - Defines protocol and platform where issuers and users can create, manage, and trade tokens leveraging built-in smart contracts.
* Bitcom - Decentralised registry of application protocols uniquely identified by an input address, proving ownership. Bitcom protocols can be concatenated together with a | character.
* [B://](https://github.com/unwriter/B), C://, D://, BCAT - Various protocols for storing files on the ledger and details how to reference them in a web page or application.
* AIP - Author Identity Protocol - Simple protocol to sign arbitrary OP\_RETURN data and decouple the signing address from the funding source address.
* MAP - Magic Attribute Protocol - Protocol that maps arbitrary data via key/value pairs on-chain.
* [HAIP - Hash Author Identity Protocol](https://github.com/torusJKL/BitcoinBIPs/blob/master/HAIP.md/) - Similar to AIP but hashes the data signed for smaller capacity devices.
* [Memo SV](https://memo.sv/protocol) - Protocol that defines various actions on Memo's on-chain social network by embedding them in OP\_RETURN transactions.
* Contact the BSV Association to have your stable, released protocol added.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://hub.bsvblockchain.org/wiki/standards-protocols-and-tools/building-on-bitcoin/application-layer-protocol.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
