Blog home

How to pin a file to IPFS with Pinata

Pinata

Published on

3 min read

How to pin a file to IPFS with Pinata

In this #Pinata101 post, learn how to pin your file to IPFS, the backbone of the decentralized web.

Cloud-based solutions like Google Drive and Dropbox set the scene for IPFS by popularizing the idea of storing files remotely and accessing them from any device, anywhere in the world. But the HTTP protocol that these centralized storage solutions were created on is not up to par for the Internet of today. And definitely not the Internet of tomorrow. IPFS is.

In this post, we’ll walk through how to pin your files to IPFS with Pinata Cloud’s web app—perfect if you’re just getting started in your web3 journey. Let’s get into it.

What is IPFS and Pinata?

IPFS is a distributed peer-to-peer protocol for storing and sharing files. It is the backbone of the decentralized web, and highly trusted by developers and the wider tech community.

Unlike traditional file protocols, namely HTTP, IPFS is not reliant on a single server or data center. Instead, files are distributed across a network of computers, creating a redundant system that is faster, more efficient, and less vulnerable to censorship or data loss.

Pinata Cloud is an IPFS adjacent service that makes uploading and managing files easy by eliminating the need to understand its technical complexities. Trusted by over 300,000 users worldwide, Pinata has powered the NFT and web3 space since 2018. Together, IPFS and Pinata offer an innovative solution that prioritizes content distribution without limits.

Step 1: Create a Pinata account

Before you can begin pinning files to IPFS with Pinata, you will need to sign up for a Pinata account. Whether you’re just beginning or a veteran developer, we have plans to accommodate all levels of users.

Head over to the Pinata website, click on the "Start Building" button in the top right corner and enter your email address. You will receive a confirmation email to activate your account. Pretty straightforward. Now on to the next step.

Step 2: Upload your file

The beauty of Pinata’s web application is in its intuitive user interface. With the help of years of feedback from developers and creators, we’ve built a simple interface that lets you get your files onto IPFS faster, and with minimal hassle.

Once you are logged into your Pinata account, you’ll land straight on your dashboard. Make sure you’re inside your “Files” tab, and click on the “+ Add Files” button in the top right corner.

You have the option to upload a folder, file or even a CID (content identifier). In this walkthrough, we will be uploading a single file. You can upload any file type, including images, videos, audio, documents, and each file may be up to 250MB.

That’s it! Told you it was easy.

What happens to my file once uploaded?

The magic begins the moment you upload your file. Once uploaded, Pinata automatically pins it to the IPFS network. Pinning a file means that it will be stored on multiple IPFS nodes, ensuring that it's 24/7 available to anyone who wants to access it. Pinning also helps to ensure permanence so that the file is not deleted from the network.

Step 3: Retrieving a pinned file

Now that your file is pinned and lives on IPFS, how do you retrieve it from amongst the masses? Pinata makes file retrieval fast and easy. Simply return to your dashboard, and you will see the details of your freshly pinned file.

Clicking on your file name will take you directly to your media. You can also copy the CID and paste it into either a public or private IPFS gateway to view it. You can also share your file to social media directly from your dashboard.

Pinata is a simple and user-friendly pinning service that allows you to easily store and retrieve files on the IPFS network. By now, you should know how to pin your files to IPFS using Pinata’s intuitive web application, and be able to retrieve them as well. When you’re ready to start pinning your files to IPFS with Pinata, sign up for an account. If you're new, we're here for you. Our support team and communities are ready and willing to help anyone who's ready and willing to build.

Happy pinning! 

Stay up to date

Join our newsletter for the latest stories & product updates from the Pinata community.

No spam, notifications only about new products, updates and freebies. You can always unsubscribe.