IPFS: The Decentralized Storage of the Blockchain

    In the world of Web3, decentralization is the way to go. Decentralized storage systems have emerged as a way to replace traditional server-based cloud storage. One of the most prominent decentralized storage is the Interplanetary File System, better known as IPFS. Currently, people store their files in centralized systems that are built upon Hypertext Transfer Protocol (HTTP). However, these centralized servers have their drawbacks. Which led to the emergence of IPFS, especially for blockchains

    This article will be your guide on everything you need to know about IPFS! Let’s see what this decentralized storage system has to offer. 

    IPFS Is a Decentralized Storage

    First, let’s understand what is decentralized storage in the first place. Decentralized storage systems came as a solution to centralized storage’s security issues. Decentralized storage, in this case, IPFS, is a peer-to-peer distributed system for storing, accessing, and sharing data. If you’re familiar with Torrent, you’ll know what that means.  

    But to put it simply, instead of retrieving files from a centralized server such as a cloud server, IPFS scatters out data to thousands of computers that are operating the network. Each computer, also known as a node, doubles as both the client and the server which eliminates the need for central servers. You can say that IPFS is just like a blockchain, but instead of being a decentralized ledger that records transactions, it’s a decentralized storage system that stores data. 


    Centralized storage systems depend on third parties to access their data through location-based Uniform Resource Locators (URLs) and Hypertext Transfer Protocol Secure (HTTPS). However, decentralized storage such as IPFS uses a content-addressed system where the content itself is a locator instead of looking for a specific location where data is stored.

    Confused? Let’s see how this is applied. 

    How Does It Work?

    You can identify IPFS files by their own unique hash. IPFS hashes are referred to as IPFS Content Identifier (CID). This means that to retrieve a certain file, you look for its hash, instead of where it is stored. IPFS uses Distributed Hash Tables (DHT) to retrieve data. For instance, if you want to download a file on IPFS, you find its hash, request the hash from the peer network, and download it directly from the node that has the data you want. 

    Here we can see that IPFS doesn’t just have blockchain use cases. Anyone can store files on IPFS regardless of what the backend is. Let’s dissect the storing and retrieval of IPFS files a bit further. 

    Let’s say a user wants to send his file to another user through IPFS:


    • The user submits the file to the IPFS client library
    • The network hashes the file and gives it its own CID.
    • The file is then distributed to thousands of nodes. 

    Storing data IPFS


    • The user search for the specific hash on the IPFS network.
    • The user’s node requires DHT to find the closest node that has the file. 
    • The user downloads the file from the node.

    Retrieving Data IPFS

    It’s as simple as that! However, anyone can access the data stored on IPFS as long as they request the right hash. This creates security and access control issues since anyone can access the content of your data. 

    Is IPFS Encrypted?

    Here comes an important question, what kind of encryption IPFS uses? There are two types of data encryption in a network: Transport-encryption and Content-encryption. 

    IPFS uses transport encryption. This means that the data is only encrypted while it is being transferred. You only need to know the hash of the data to decrypt the file and look at its content. 

    Transport Encryption

    However, content encryption utilizes an additional password. Users can encrypt their data with a password that only holders of that password can decrypt the file. This somewhat resembles the blockchain protocol of encryption that utilizes public-key cryptography

    Content Encryption

    But doesn’t it mean that IPFS files are not secure? Well yes. However, IPFS claims that the lack of encryption is intentional to let users have the freedom to choose whichever encryption protocol they like. 

    IPFS and Blockchain

    So, how do IPFS and blockchains go hand in hand? Well, blockchains are decentralized ledgers that record transactions, however, blockchains can’t store large amounts of data. Storing large files on the blockchain can be slow and expensive, and thus, these files can be stored off-chain on a decentralized system such as IPFS. This way, storing files on IPFS minimizes the load on the blockchain. 

    In addition, blockchain can use IPFS hashes to point to off-chain data since IPFS uses content addressing. For example, NFTs that are stored on the blockchain can point to their metadata on IPFS. This is because NFTs are non-fungible tokens that are written on the blockchain. Storing NFTs’ metadata such as media files can be very expensive to do on-chain. This is why most NFT collection points in their smart contracts to their metadata on centralized servers, which in turn point to media files stored on IPFS. 

    NFT Metadata-IPFS

    Advantages of IPFS

    Let’s see some of the benefits IPFS provides. 

    • Decentralization: The decentralization aspect of IPFS increases the security of the stored data. That’s because there is no central point of attack like there is with centralized storage systems. 
    • Content Addressing: In IPFS, files are found by their content instead of their location, which makes it easier to verify data integrity. 
    • Offline Access: IPFS allows nodes to cache and store content they have accessed in the past. This means that even if some nodes are offline, they can still access content it has previously retrieved. 
    • Censorship Resistance: Since there is no central authority governing the decentralized storage, IPFS promotes censorship resistance. 
    • Reduced Bandwith Costs: When multiple users request the same content, IPFS serves the content from nearby nodes reducing long-distance data transfers. 

    Downsides of IPFS

    Everything in technology has its ups and downs, and so does IPFS. Although it provides a lot of benefits, IPFS has its limitations. 

    • Security: IPFS doesn’t provide encryption or access control, which can make the data subject to hacking. 
    • Privacy: Since there is no access control, the content hosted on IPFS is available to anyone. This can raise privacy concerns, especially if sensitive information were stored on the network. 
    • Scalability: Just like the blockchain, IPFS is a distributed network, and thus, scalability is a problem. IPFS faces challenges in scaling to handle a large number of users and a massive amount of data. 
    • Data Persistence: Data is not persistent on IPFS. It is only available if nodes kept pinning the data. If no one is pinning it, it can disappear from the network. 

    IPFS vs. HTTP

    Since IPFS is a decentralized solution for central servers, we’ve got to put IPFS side to side-with HTTP. Check out the below table by 101 blockchains to see the difference between the two. 

    HTTP vs. IPFS

    Is IPFS the Best Blockchain Storage?

    Yes. It wouldn’t make sense for the decentralized blockchain to work with a centralized storage system. IPFS offers decentralized storage, content addressing, and data resilience. It complements the blockchain by efficiently storing off-chain data, reducing transaction costs, and ensuring data integrity through CIDs. IPFS also serves as a great solution to store NFT metadata. Decentralization is still in its infancy, and as more platforms adopt it, the more development it will foresee.


    Please enter your comment!
    Please enter your name here

    Stay in the Loop

    Stay in the loop with blockchain Witcher and get the lastest updates!


    Latest stories

    You might also like...