Filecoin: Decentralized Cloud Storage & CDN

Written by

Read time

6 min

Filecoin aims to be marketplace for data storage and retrieval, positioning itself to compete with data giants such as Amazon, Microsoft and Google and content delivery networks like Cloudflare. The Filecoin blockchain builds on the content addressing of IPFS to add long-term data persistence using cryptoeconomic incentives. Filecoin and IPFS are both developed by Protocol Labs.


The FIL token is a utility token used to purchase storage and retrieval services, to incentivize nodes to provide and expand storage resources, and to maintain network consensus.

Storage Technology & Consensus Mechanisms

While Filecoin borrows technologies from IPFS such as content addressing, CIDs and Merkle DAGs, Filecoin nodes do not join or participate in the public IPFS DHT. On Filecoin, each CID refers to 32GB storage sector, and public IPFS nodes cannot view the contents of a CID without the right decryption provided by the Filecoin protocol.

On Filecoin, below two algorithms do most of the heavy lifting:

  • Proof-of-Replication (PoRep): miners are rewarded in Filecoin if they can prove they’ve received the cryptographically stored information from the client (step 4 above).
  • Proof-of-Spacetime (PoSt): miners are rewarded and not slashed if they can prove that data in the client’s contract has been kept unchanged over a period of time.

The PoRep algorithm allows for miners to proof that data has been replicated to their own unique dedicated storage. This allows for miners to prove that they are indeed storing the number of unique physical copies requested by clients. This is achieved by “sealing” every replica of data independently. This is achieved by requiring storage miners to store pseudo-random permutation of the stored data unique the miners public key. If a miner commits to storing a certain number of replicas, each replica will have its own unique pseudo-random permutation that makes it unique.

Once files are properly stored and sealed, the miner generates the Merkle root of the replica and a proof of sealing. When the miner is challenged regarding whether or not they are indeed storing the content, the miner receives a random challenge which determines a specific leaf of the Merkle tree of the unique replica, based on the Merkle tree root. The miner then generates a proof of knowledge using the Merkle path that leads through the Merkle root.

PoSt builds on this primitive and proves that the uniquely stored replica has been stored over a certain period of time. When a random challenge is received, the miner generated proofs of replication in sequence, using the output of a proof as an input of the next over a specific amount of iterations corresponding to the storage duration. The PoSt mechanism is used to audit miners to ensure they are storing the right data for the right amount of time.

To become a storage miner, miners must first pledge both a storage pledge and a consensus pledge as collateral. If miners misbehave either maliciously or negligently by not executing storage contract properly, their pledge is slashed and burned (removed from the total circulation of Filecoin) by the protocol. This acts both as a disincentive for malice, as well as providing deflationary pressure on the token. 75% of block rewards earned by miners vest linearly over 180 days while 25% are made immediately available to improve miner cash flow and profitability.

In Filecoin, data storage is managed through storage contracts that are settled on the Storage Market – for more details please see the Storage Process & Pricing Mechanism section.

Apart from storage miners, Filecoin has another class of miner: the retrieval miner. While storage miners are responsible for storing data, retrieval miners are responsible for retrieving data and serving it to clients. Retrieval miners are not required to pledge collateral to become a miner and thus many storage miners tend to also take on the role of retrieval miners. Retrieval miners can obtain data directly from clients, thus enabling third party storage services directly linked to certain retrieval and storage nodes, or through the Retrieval Market. On the retrieval market, retrieval miners are rewarded in FIL tokens for retrieving and serving data to clients.

The Filecoin network uses a public blockchain ledger to track all storage allocations of all network participants. Whenever a new block is mined, the network checks if the required proofs for all stored data is available and if it is valid. Under the circumstance that proofs are missing or invalid, the miner is penalized by having some of their collateral removed. From here, if a specific fault threshold is exceeded, the network settles the storage order as failed and attempts to retrieve the faulty data from other nodes in order place a new storage order to the Storage Market. If the network is unable to retrieve the faulty data (i.e., ever storage miner storing this piece is faulty), that means the data is lost. In this case, the client gets refunded.

Storage Process & Pricing Mechanism

When new data is to be stored on the Filecoin network, a storage user must connect to a storage provider through the Filecoin storage market and negotiate storage terms, before placing a storage order this is handled through Filecoin’s Storage Market. In the Storage Market, users must initiate a deal negotiation to start the storage process:

  1. Discovery – The client identifies miners and determines their current asks.
  2. Negotiation – Both parties come to an agreement about the terms of the deal, each party commits funds to the deal and data is transferred from the client to the provider.
  3. Publishing – The deal is published on chain, making the storage provider publicly accountable for the deal.
  4. Handoff – Once the deal is published, it is handed off and handled by the Storage Mining Subsystem. The Storage Mining Subsystem will add the data corresponding to the deal to a sector, seal the sector, and tell the Storage Market Actor that the deal is in a sector, thereby marking the deal as active.

During this process, the user decides which type of erasure encoding (EC) is to be used and the replication factor thereof. With EC, data is broken down into constant-size fragments, which are each expanded and encoded with redundant data, so that only a subset of the fragments are required to reconstruct the original file. The replication factor refers to how often the data should be replicated to more storage sectors of the storage miner. Once the storage miner and the user agree on the terms, the data is transmitted to a storage miner and is stored in a storage miner’s storage sector.

If users want to further increase redundancy, they need to engage in additional storage deals with additional storage providers, as there still exists the risk that one storage miner goes offline and with it all of their pledged storage sectors. Applications such as NFT.Storage and Web3.Storage built by Filecoin on the Filecoin protocol solve this through storing files with multiple storage miners, however at a protocol level users must manually engage with multiple storage miners.


  • Baseline minting (770 million FIL): minted based on network performance relating to reaching storage capacity targets, incentivizing growing the network’s storage capacity
  • Simple minting (330 million FIL): minted independent on a 6-year half life based on time (97% minted in approximately 30 years)
  • Mining reserve (300 million FIL): community controlled reserve tokens, with the purpose of incentivizing future types of mining
  • Initial Coin Offering (200 million FIL): vesting over 3 years from protocol launch on October 15th, 2020
  • Protocol Labs (300 million FIL) & Filecoin Foundation (100 million FIL): vesting over 6 years from protocol launch on October 15th, 2020
  • Total slashed (30.5 million FIL) as of time of writing (see https://filfox.info/en/address/f099)

This gives us a (current) fully diluted circulation of FIL of roughly 1.97 billion tokens. The tokenomics are designed to incentivize storage and contract completion, while further incentivizing the expansion of total storage on the network.

Figure 1: Max and Min Minting from Storage Mining and Max Baseline Minting. Source: https://filecoin.io/blog/filecoin-circulating-supply/


All references were accessed between May 5th and 31st, 2022.

Coinlist (2017) Filecoin Token Sale Economies. Available at: https://coinlist.co/assets/index/filecoin_2017_index/Filecoin-Sale-Economics-e3f703f8cd5f644aecd7ae3860ce932064ce014dd60de115d67ff1e9047ffa8e.pdf

File.App (n.d.) Available at: https://file.app/

Filecoin (2020) Date Transfer in Filecoin. Available at: https://spec.filecoin.io/systems/filecoin_files/data_transfer/

Filecoin (2020) Storage Market in Filecoin. Available at: https://spec.Filecoin.io/systems/Filecoin_markets/storage_market/

Filecoin (2020) Understanding Filecoin Circulating Supply. Available at: https://filecoin.io/blog/filecoin-circulating-supply/

Filecoin (2020) What sets it apart: Filecoin’s proof system. Available at: https://filecoin.io/blog/posts/what-sets-us-apart-filecoin-s-proof-system/

Filecoin (2021) How storage and retrieval deals work on Filecoin. https://Filecoin.io/blog/posts/how-storage-and-retrieval-deals-work-on-Filecoin/

Filecoin (n.d.) IPFS and Filecoin. Available at: https://docs.Filecoin.io/about-Filecoin/ipfs-and-Filecoin/

Filecoin (n.d.) IPFS. Available at: https://spec.filecoin.io/#section-libraries.ipfs

James Duade (2021) FileCoin: Decentralized Cloud Storage Competitor To AWS, Microsoft Azure, And Google Cloud. Available at: https://seekingalpha.com/article/4419553-Filecoin-decentralized-cloud-storage-competitor-aws-microsoft-google


Related content