This is it. This is what distinguishes blockchain application development from that of non-blockchain applications: on-chain data. Do you wonder where the data associated with a Dapp is stored? Some are stored on the blockchain infrastructure (on-chain), and others in traditional databases and files (off-chain). In this chapter, you’ll learn first about the concept of on-chain data introduced by the inclusion of blockchain features in an application. Then you’ll learn to design and develop Dapps that deal with a combination of on-chain and off-chain data.
So what exactly are these two types of data in the context of blockchain programming? In general, any data stored on the blockchain is called on-chain data, and anything else is off-chain.