## 2 Blockchain-Based Data Storage Methods: On-Chain, Off-Chain, and Hybrid Approaches
### On-Chain Data Storage Methods  
A blockchain is a data structure composed of blocks that are chronologically and cryptographically linked. Each block contains transactions occurring on the network along with relevant metadata. This structure ensures immutability, transparency, and verifiability, enabling secure data storage on the blockchain [21]. The structure of a block is illustrated in Figure 2. Each blockchain block consists of three main components:  
* _Block Header_: Contains the unique hash value that identifies the block and maintains the integrity of the chain by referencing the previous block's hash. The timestamp records the time the block was created, while the Merkle root serves as a cryptographic summary that ensures the integrity of all transactions within the block;
* _Transaction Data_: Represents the primary data component stored within the block, including sender and receiver addresses, transaction amounts, and additional metadata. Transactions are structured in a Merkle tree, allowing them to be efficiently hashed and verified;
* _Block Metadata:_ Includes the nonce value, which is used in the Proof-of-Work (PoW) mechanism to find the correct hash, and the block size, which defines the total amount of data stored within the block. Data storage on the blockchain is achieved by maintaining information in a structured and encrypted format within blocks. This structure not only preserves data integrity but also guarantees decentralization [1; 53]. Merkle trees facilitate the verification of stored data, while each node retains a copy of the block data, thereby enhancing network security [45; 54]. However, on-chain data storage presents scalability challenges when dealing with large datasets. Since all network nodes are required to store a full copy of the blockchain, storage demands continuously increase, potentially impacting transaction processing times [18; 47]. On-chain data storage offers security, immutability, and transparency by recording data directly on the blockchain [12; 37]. Since blockchain-stored data is verifiable and  
Figure 1: Blockchain-based data storage models: On-chain (all data stored on the blockchain), Off-chain (data stored externally with only references or hashes on-chain), and Hybrid (critical data on-chain, larger datasets off-chain). Figure 2: Blockchain block structure for on-chain data storage. Each block comprises a header (hash linking to the previous block for integrity), transaction data (records all transactions), and metadata (includes nonce and Merkle root for consensus and verification). tamper-proof across the entire network, it provides a significant security advantage, particularly for sensitive data storage in sectors such as healthcare [55]. Due to its decentralized architecture, data are more resistant to attacks targeting centralized servers [39; 48]. Furthermore, all transactions are cryptographically signed and distributed across all nodes in the blockchain, which ensures data integrity and prevents unauthorized access [1; 46; 56]. However, on-chain data storage methods come with several critical limitations. Firstly, storing data directly on the blockchain is highly costly, as each transaction must be propagated across the network and requires transaction fees paid to miners [57; 58; 59]. Additionally, recording large datasets on the blockchain increases network load, leading to longer transaction processing times and a reduction in overall efficiency [47; 54]. As the blockchain expands, every node must store a complete copy of the ledger, thereby escalating storage requirements and limiting scalability [18; 47]. Considering these advantages and challenges, while data storage methods on the blockchain provide high security and immutability, they have significant limitations in terms of cost and scalability. Alternative approaches such as off-chain and hybrid solutions have been developed to address these disadvantages, especially when it comes to large datasets.