Cointime

Download App
iOS & Android

How to Create an ERC721 NFT the Best Way in 5 Minutes

So an NFT is simply a piece of information that lives on the blockchain, represented by a visual image. This is not a guide on how to design NFTs. For that you need to learn digital design with tools such as Illustrator and Photoshop.

Btw if you want to create your own NFT collection I wrote a massive guide to show you everything step by step from own experience launching collections here: https://merunas.gumroad.com/l/nft-guide

Remember, an NFT is a regular image + some data stored in the blockchain.

To keep it simple, go to Deep AI text to image generator and type whatever text you want, the AI system will create an image from it like so:

And this is the resulting image which we’ll turn into an NFT:

Now that you have the image that will be used as an NFT, you need a place to store the image so it’s accessible online. Here are the options:

Storing the image on-chain

You can compress and encrypt the image into a string that can be stored in the blockchain directly. Nouns is a very popular project and they do that.

This is the best approach because the data is fully decentralized and will stay in the blockchain permanently so others can access it anytime.

To do that, you’d create an ERC721 smart contract and store the image of the NFT in a string state variable.

However we won’t do that because it’s a bit of a difficult process since you can’t just compress the images you need a specific way to convert them to string so they aren’t massive.

Storing a base64 string would easily take many millions units of gas in Ethereum. It’s just not a simple process.

Storing the image in IPFS

This is the most common approach and the one we’ll take where the image is store in the decentralized service IPFS.

Files on IPFS stay in a network of nodes sharing and storing the image of your NFT. I wrote a lot about how to store your IPFS files online forever here. However today we’ll use a great tool.

That tool is called nft.storage and it’s great because they do all the setup and hard work for you. You just upload and the image stays online forever.

You’ll see a page like this once logged in:

Simply click on the Upload button. Then select the nft image you’ve created and click on upload.

You’ll see the uploaded file.

Click on actions and “Copy IPFS Url”. You’ll need it to create the metadata which is the key information NFT marketplaces need to work with.

Now you’ll need to deploy the NFT contract. Continue reading!

Btw if you want to create your own NFT collection I wrote a massive guide to show you everything step by step from own experience launching collections here: https://merunas.gumroad.com/l/nft-guide

Creating the NFT ERC721 smart contract

The ERC721 standard is the one you must use to deploy your NFT. Go to remix ethereum and click on this icon to create a new smart contract:

Simply call it NFT.sol and add the following code:

That’s the simplest NFT smart contract you’ll ever find. It imports the popular openzeppelin libraries which are the standard when it comes to smart contracts and it adds the minting functionality to create 1 NFT on deployment.

As you can see the parameters are _name_symbol and _metadataUrl where the name is your NFT name, the symbol for your NFT which is like a short name of 4 characters and the metadata url.

The contractURI() function returns the metadata and it’s required by opensea.

What is metadata? The metadata is the link between your smart contract and your image. It’s a .json file. It contains the name, image and any other attributes you want to add to the NFT so that marketplaces like opensea can show users that data.

Before deploying the NFT contract, you want to create the metadata and upload it to nft.storage. Let’s see how it’s done:

Creating the NFT metadata

Simply create a new file called metadata.json and add the following parameters:

You can change the name and description. The external_url is where you want users to go when they click on your NFT. In this case it’s the same for the image and url so people see the image.

To get the image url go to nft.storage and copy the IPFS url which will look like this:

ipfs://bafkreidhvbks723vbhipmxp4fv75yki7h2v3y3onbbnhisttg6iz3wnacq

However that’s not accessible by browsers. Simply change the ipfs:// part to https://ipfs.io/ipfs/ and it will look like this:

https://ipfs.io/ipfs/bafkreidhvbks723vbhipmxp4fv75yki7h2v3y3onbbnhisttg6iz3wnacq

You can try to open that in your browser and it will show the image.

Now simply upload the metadata.json file you just created to nft.storage like before. Once uploaded, go to Actions > View URL and copy the URL.

Then go back to your remix.ethereum.org NFT.sol smart contract and deploy the contract with the NFT url like so.

That should be it! Your NFT contract will be created, the token will be minted, the metadata deployed to nft.storage will be connected to the smart contract and the image will be received from the metadata to show it on opensea.

If you can’t see the video for any reason here’s a gif of it:

Your NFT is ready and you now know how to create NFTs. This is just for 1 single NFT but you can repeat the process with many NFTs.

NFT
Comments

All Comments

Recommended for you

  • SK Hynix Submits IPO Application in the U.S. with Ticker 'SKHY'

    On June 24, according to market news, SK Hynix has submitted an IPO application in the United States, planning to list on NASDAQ under the ticker 'SKHY'. Fubon Securities, Citigroup, Goldman Sachs, and JPMorgan Chase are the underwriters for its initial public offering (IPO).

  • Elon Musk's Net Worth Drops $340 Billion in 8 Days, No Longer a Trillionaire

    On June 24, according to reports, the world's first trillionaire sat on his 'throne' for less than two weeks before 'falling from grace.' As of June 24, Elon Musk's net worth has fallen below $1 trillion. According to the Bloomberg Billionaires Index, Musk's current net worth is $957 billion, a significant decrease of $340 billion from the peak of $1.3 trillion just eight days ago. However, even after this decline, Musk still remains far ahead on the wealth rankings.

  • U.S. Optical Communication Stocks Rebound in Pre-Market, Mavenir Technologies Up Nearly 2%

    On June 24, U.S. optical communication stocks, which collectively declined yesterday, rebounded in pre-market trading today. Among them, Qorvo, Credo Technology, and GlobalFoundries rose over 3%. Applied Optoelectronics, POET Technologies, Astera Labs, AXT Inc, Nokia, Tower Semiconductor, and Coherent increased by more than 2%. Mavenir Technologies rose nearly 2%, while Corning increased by 1.4%.

  • Two Major Whales Open $8.3 Million MU Short Position, Anticipating Continued Stock Price Decline Post-Earnings Report

    On June 24, according to monitoring by Hyperinsight, as Micron's earnings report approaches, trading activity for MU contracts on the Hyperliquid platform has significantly increased, with a 24-hour trading volume of approximately $459 million and a total open interest value of $195 million. On-chain detection by BlockBeats indicates that this morning the contract price reached about $1,030 before rebounding to $1,091. Last night and this morning, two major on-chain whales opened MU short positions totaling $8.3 million, with an average entry price of about $1,071, currently facing a slight unrealized loss, and the recent liquidation line is at $1,470. It is reported that the two addresses currently hold a total of $55.5 million in various U.S. stock short positions, one of which belongs to the well-known trader CBB.

  • SK Hynix Shares Rise 5.5% in After-Hours Trading

    On June 24, SK Hynix shares rose 5.5% in after-hours trading. In news, SK Hynix is seeking to begin trading American Depositary Receipts (ADRs) on July 10, planning to issue 17.9 million new shares at a price of 255,500 Korean won per share, aiming to raise up to 45.45 trillion won (approximately 29 billion USD).

  • Storage Stocks Slightly Rebound, Micron Technology Rises Over 3%, Market Focuses on After-Hours Earnings

    On June 24, U.S. storage stocks, which had seen a significant drop the previous night, collectively rebounded slightly before the market opened today. Micron Technology rose over 3%, SanDisk increased by more than 2%, while Western Digital, Phison Electronics, and Seagate Technology each gained over 1%. In terms of news, the market is focused on the earnings report from Micron Technology, which is set to be released after the market closes on Wednesday. This report is expected to provide key insights into whether the demand for artificial intelligence infrastructure remains strong enough to support this year's upward trend.

  • SK Hynix Plans to Raise Up to 45 Trillion Won Through ADR Listing

    SK Hynix plans to raise up to 45 trillion won (approximately 29 billion USD) through an ADR listing.

  • Ningquan Asset Issues Stern Warning: A-Share Popular Stocks May Plummet by 80-90%, Collapse Could Be Imminent

    On June 24, Ningquan Asset, founded by Yang Dong, pointed out in its '2026 Mid-Year Investment Report' released on the 23rd that a large number of popular A-shares are likely to drop by 80% or even more than 90% in the future, and we can no longer participate. We do not have the ability to take risks without getting burned, and taking such risks would be irresponsible to our investors. Currently, quantitative funds are occupying an increasing share of the market, and the rapid information dissemination facilitated by the internet makes it difficult to predict the form and speed of a future collapse. Given the current level of market bubbles and the extreme differentiation, we are concerned that the timing of a collapse may not be far off. Moreover, a stock price collapse does not need to wait for a slowdown in demand or a surge in supply; simply being excessively overvalued can trigger a collapse.

  • Draft Financial Law Submitted for Initial Review by NPC Standing Committee

    According to Xinhua News Agency on June 24, the "Draft Financial Law of the People's Republic of China" was submitted for initial review by the Standing Committee of the National People's Congress on June 23. The financial activities referred to in the financial law are defined as monetary and credit activities directly related to deposits, loans, insurance, securities, futures and derivatives, funds, trusts, payment settlements, and credit reporting conducted by natural persons, legal persons, and unincorporated organizations. The state will bring all financial activities under regulation and will legally combat illegal financial activities. The draft financial law includes multiple provisions regarding financial products and services, trading venues, illicit gains, and overseas financial activities, such as: - No unit or individual may provide or indirectly provide financial products and services without approval, registration, or filing. - No unit or individual may establish trading venues for financial products or organize centralized trading and related activities in any form without the approval of the State Council or the financial regulatory department of the State Council. - No unit or individual may gain benefits from financial illegal activities; any illegal gains, except for those returned in accordance with the law, shall be confiscated. Those who organize or instruct others to engage in financial illegal activities, or assist or facilitate others in committing financial illegal acts, shall be ordered to rectify by the financial regulatory department of the State Council or other units specified by laws and administrative regulations, and shall be punished according to the types and scope of penalties prescribed in the previous clause, based on the circumstances of the violation and the harmful consequences. - Engaging in financial activities as stipulated in Article 3 of this law outside the territory of the People's Republic of China, which endangers the national financial security of the People's Republic of China, disrupts the financial order within the territory, or harms the legitimate rights and interests of citizens and domestic organizations, shall bear legal responsibility according to the law. Earlier reports indicated that on March 20, 2026, the Ministry of Justice, the People's Bank of China, the Financial Regulatory Administration, the China Securities Regulatory Commission, and the State Administration of Foreign Exchange jointly solicited public opinions on the "Draft Financial Law of the People's Republic of China."

  • Thailand's Central Bank Keeps Interest Rate Steady Amid Economic Risks from Middle East Situation

    On June 24, as the U.S. and Iran seek to reach a lasting peace agreement, Thailand's central bank decided on Wednesday to maintain the policy interest rate at 1.00%, in line with market expectations, while reassessing the economic impact of the war in the Middle East. Although the risks posed by the war are diminishing, uncertainty remains high. Last week, several central banks, including the Federal Reserve, also adopted a wait-and-see approach, while Japan, Indonesia, and the Philippines implemented interest rate hikes to mitigate the war's impact on their economies. Before a ceasefire agreement in the Middle East is reached, the Bank of Thailand warned that domestic economic growth would slow due to rising costs squeezing businesses and weakening household purchasing power. The tourism sector, a crucial pillar of Thailand's economy, has also been affected by rising costs and travel restrictions. Even if geopolitical threats diminish, the lagging effects of the conflict will continue to pose challenges to the economy. Additionally, the central bank must contend with food supply risks triggered by the El Niño phenomenon and the ongoing uncertainty surrounding U.S. tariff policies. Many economists believe that the Bank of Thailand may maintain its current stance for the remainder of the year, keeping a loose monetary policy to support the still fragile economy.