Documentation
  • INTRODUCTION
    • What is ENS?
    • What is a dWebsite?
    • What is IPFS/IPNS?
    • What is eth.limo?
      • Gateway Basics
        • DNS over HTTPS
  • Beginner
    • How to register an ENS domain/name
    • Setting up a GitHub Repository
    • How To Install IPFS Locally
      • IPFS Desktop (Windows)
      • IPFS Desktop (Linux)
      • IPFS Desktop (Mac)
    • How to use IPFS/IPNS
      • Uploading to IPFS
        • Self-Hosting Instructions for IPFS and IPNS
        • Hosting using a pinning service
    • Setting Up Your ENS Name/Domain
      • Updating Your ENS Content Records
      • Content Hash Overview
        • Understanding Content Hashes, IPNS, and IPFS for ENS
        • Understanding IPFS Content Identifiers (CIDs)
  • IPFS Pinning Providers
    • Filebase
      • Using the Filebase Public IPFS Gateway
      • Filebase IPFS Pinning
  • STATIC SITE BUILDERS/TEMPLATES
    • -
  • Intermediate
    • Using eth.limo with IPFS (Kubo)
    • -
    • -
    • -
  • .ART Resolution
  • .gno Resolution
Powered by GitBook
On this page
  1. Beginner
  2. Setting Up Your ENS Name/Domain
  3. Content Hash Overview

Understanding IPFS Content Identifiers (CIDs)

What is a CID?

The string of letters and numbers you see in an IPFS link is its "Content Identifier" or CID. A CID is a unique label used to point to a specific piece of content within the IPFS network. This unique identifier ensures that content is always retrievable in its original form.

Types of CIDs

IPFS uses two types of CIDs:

CID Version 0

When IPFS was first designed, it used base 58-encoded multihashes as the content identifiers, which looked like this:

QmQbeKEi4XJ9yLL2nyFKxpuPyrfqmHBGtRj3EhWcSvQaSD

Many applications and services still use CIDv0 by default, but this format is nearing replacement.

CID Version 1

The IPFS project is transitioning to CIDv1 as the new default format. CIDv1 is a more flexible and future-proof approach. An example of a CIDv1 looks like this:

bafybeibbr2r6b3hd3p5jggobmgacm7f4523ijyza364szdeyrw3b4uy7ei

CIDv1 includes several leading identifiers that provide additional information:

  • Multibase Prefix: Specifies the encoding used for the rest of the CID.

  • CID Version Identifier: Indicates which version of CID is being used.

  • Multicodec Identifier: Specifies the format of the target content, helping both people and software understand how to interpret the content once fetched.

These leading identifiers ensure forward-compatibility, allowing different formats to be used in future versions of CID.

Troubleshooting CIDs

Different CID Shows After Setting

When you set a CIDv0 on your ENS name, it will be converted to a CIDv1. For instance, if you enter a CIDv0 like this:

QmQbeKEi4XJ9yLL2nyFKxpuPyrfqmHBGtRj3EhWcSvQaSD

Once it's set on your ENS name, it will be converted to look like this:

bafybeibbr2r6b3hd3p5jggobmgacm7f4523ijyza364szdeyrw3b4uy7ei

Example Scenario

If you edit the Content Hash record for your ENS name and set it to:

ipfs://QmQbeKEi4XJ9yLL2nyFKxpuPyrfqmHBGtRj3EhWcSvQaSD

You will see your record reformatted to the CIDv1 version of the IPFS hash:

ipfs://bafybeibbr2r6b3hd3p5jggobmgacm7f4523ijyza364szdeyrw3b4uy7ei

By understanding these details about CIDs, you can more effectively manage and troubleshoot your ENS-linked content. The eth.limo service gateway makes this process straightforward, ensuring your content is always accessible and correctly formatted.

PreviousUnderstanding Content Hashes, IPNS, and IPFS for ENSNextFilebase

Last updated 11 months ago