blank Skip to main content

NFTs for Real Estate: Exploring the Concept and Creating Tokens in Python, JavaScript, and Solidity

Real estate is one of the industries that’s moving step by step towards digitalization, striving to automate operations and minimize the risk of fraud. Adopting non-fungible tokens (NFTs) seems like a reasonable next stage of this journey. However, it’s not always obvious how to leverage NFTs, what solutions to create, and what pitfalls to expect.

In this article, we focus on the practical use of NFTs for selling physical properties. We discuss the concept of an NFT-driven real estate marketplace with its pros and cons. We also show examples of code for creating non-fungible tokens on the Ethereum and Algorand blockchains in various programming languages.

What are NFTs?

A non-fungible token is a digital blockchain-based asset that has a unique identification code and metadata that distinguish it from other tokens. NFTs can represent objects from the real world and can be bought and sold online for cryptocurrency or fiat money.

How is an NFT different from other blockchain tokens?

There are two main types of blockchain tokens: fungible and non-fungible. There also exist semi-fungible tokens, but they are out of the scope of this article.

The difference between fungible and non-fungible tokens is that you can create as many fungible tokens as the blockchain platform allows, whereas you can create only one non-fungible token with a unique ID to represent any given object.

Fungible tokens are divisible and non-unique. Many users can possess any number of units of a specific kind of token. NFTs are unique and only one user can possess a given non-fungible token.

Thanks to the strengths of blockchain technology, which makes NFTs reliable, secure, fast, and effective, you can:

  1. Prove ownership of a digital or physical object with a specific NFT
  2. Easily trade or exchange assets represented by NFTs by simply transferring NFTs within a blockchain network
  3. Keep immutable and transparent asset sales records on the blockchain

These opportunities make NFTs useful for business purposes within different industries. Let’s take a closer look at how real estate can benefit from the use of non-fungible tokens and what use cases exist.

Read also:
Key NFT Business Use Cases, Benefits, and Nuances to Consider

How can you use NFTs in real estate?

In real estate, NFTs represent properties. A real estate owner receives payment in tokens via a crypto marketplace, and the buyer receives an NFT in their digital wallet. This NFT represents ownership of a particular real estate object.

The blockchain isn’t new technology for real estate, since smart contracts are already used to digitally arrange sales and payments. A smart contract can also be used to store information about an NFT and act as a self-executing program ensuring that all sales agreement conditions are met.

Non-fungible real estate tokens have to contain lots of data, and storing them on the blockchain can be too costly. That’s why smart contracts often contain a link to the work or assets an NFT represents, which can be accessed by the owner only. The asset-related details smart contracts can store may include:

  • Ownership information
  • Real estate location
  • Investors’ rights
  • Parties entitled to royalties each time the NFT is sold
  • Ownership history of the asset

NFTs are used to trade physical and virtual real estate.

NFTs for virtual real estate

Virtual real estate is a plot of land or a building that exists in a virtual world. Such properties can be obtained by purchasing associated NFTs for cryptocurrency, and each world usually has its own cryptocurrency. NFTs help users verify the authenticity and ownership of virtual land purchased in a game or other metaverse platform.

Virtual real estate is a significant part of the metaverse, which is rapidly developing. Enthusiasts invest in NFT real estate within virtual worlds, hoping to profit from it in the future. The metaverse market is expected to hit $596.47 billion by 2027. And Gartner expects that by 2026, 25% of people will spend at least one hour a day in the metaverse.

The Metaverse is a collective virtual open space, created by the convergence of virtually enhanced physical and digital reality. It is physically persistent and provides enhanced immersive experiences.

Activities that take place in isolated environments (buying digital land and constructing virtual homes, participating in a virtual social experience, etc.) will eventually take place in the Metaverse.

Gartner’s definition of metaverse

Most people who buy virtual land consider it an investment. In May 2022, a Decentraland Mega Tower was sold for over $238,000. And the current record belongs to Sandbox: a piece of their virtual land was sold for $4.3 million in 2021.

NFTs for physical real estate

NFTs that represent physical real estate can be traded on special marketplaces. To link tokens to real property, you can tokenize the property as an entire asset or as fractional shares.

Let’s briefly discuss the difference between fractional ownership tokenization and an entire asset tokenization:

Fractional ownership (FO) tokenization is relatively simple and works the same way as crowdfunding. Investors can buy a specific number of shares via blockchain tokens (either semi-fungible or non-fungible) representing ownership in the asset. To make it all legal, you need to research the applicables laws in the country you operate in, especially as tokens can be considered a type of security just like stocks. For example, in the US, you’ll need to keep an eye on upcoming SEC regulations related to NFTs and the entire FinTech industry.

Entire asset tokenization is more complicated and requires the conversion of actual property deeds into NFTs. To fully embrace this approach, the NFT community is waiting on lawmakers to pass legislation for creating a new asset class that allows deeds to exist in the form of NFTs. However, despite the technical and legal challenges, some companies have started wrapping real estate into legal entities and creating tokens that represent ownership of those entities.

For example, a house in Florida was sold at auction as an NFT. The person with the highest bid — $653,163 worth of ETH — now holds the NFT, signifying ownership of a four-bedroom house on-chain.

In this article, we mainly focus on how to use NFTs in physical real estate. Let’s explore how the concept of an NFT platform can work for selling or renting property.

Case Study:
Evaluating Smart Contract Security for Decentralized Finance (DeFi)

How does an NFT marketplace work for real estate?

The embodiment of the NFT real estate concept is a dedicated platform with its own marketplace where people can buy and sell property as NFTs by connecting their crypto wallets.

How would such a platform function and what conveniences would it bring?

The most essential and interesting part here is property digitalization. Here is a description of the main idea:

  1. The legal documents for the property to be sold are processed and converted into digital assets.
  2. These digital assets are minted as NFTs on a marketplace. Ideally, an asset should be created and minted on the same platform; however, using other suitable marketplaces for minting would also work.
  3. The minted NFT contains the legal paperwork, sales data, and disclosure agreements for the property. It’s furnished with the required technical description and is listed for sale.
  4. Users should connect their crypto wallets to the NFT marketplace to store and initiate transactions on the platform.
  5. The interested parties initiate the process of exchanging the NFT asset.

NFTs are pushing real estate into a new chapter — the chapter of automation — which represents significant progress. With NFTs, payments for purchasing and renting properties can be completed much faster than they are now. Also, moving towards digitalization will make the real estate market more accessible to a wider range of investors.

However, adopting NFTs in the real estate industry — for instance, by developing an industry-centered marketplace — can be challenging. Let’s discuss both the pros and cons of using non-fungible tokens for real estate.

Related services

Blockchain Consulting and Development Services

NFT-driven solutions for the real estate industry: benefits and challenges

NFTs promise traceable, secure records of ownership for different real estate investments and make the real estate market more accessible to a broad investor base. The blockchain as the core technology behind NFTs can potentially prevent illegal activities like tax evasion.

Let’s take a closer look at four key benefits NFTs can potentially bring to property owners, real estate agencies, and investors when powering a comprehensive real estate marketplace:

Enhance the security of digital transfers. NFT marketplaces specifically developed for real estate can assure improved security and data integrity of digital transactions by leveraging the strengths of blockchain technology. Such platforms can help parties significantly decrease the risks of cyber fraud and efficiently trade various types of property. For example, the real estate transaction platform Propy, which has already sold an apartment in non-fungible tokens, is launching a platform in the US to trade physical property in NFTs.

Improve property ownership verification. NFTs are minted via a blockchain, which ensures immutability and security. By minting title deeds and other property documents as non-fungible tokens, parties can:

  • Save effort and money on handling paperwork and ordering notarial services to prove ownership of property
  • Decrease the risk of fraud

Accelerate the entire process of purchasing and renting property. NFTs have the potential of making real estate-related deals more convenient and simple for all parties involved.

Apart from quick and simple property ownership verification, NFT real estate platforms can help businesses:

  • Mint assets right on the platform
  • Easily place properties for sale or rent
  • Conveniently search for properties
  • Ensure fast payment via cryptocurrency

Also, if you create a trusted NFT marketplace, you can ensure a quick background check of property sellers and buyers.

Simplify mortgages. Real estate agencies can potentially adopt NFTs to digitize property mortgages. For example, LoanSnap — a mortgage lending agency — already minted NFTs on the Bacon Protocol platform in 2021 [PDF]. Their idea was to send a minted loan NFT to a homeowner. The homeowner then can make payments to the Bacon Protocol. According to LoanSnap, third-party minting reduces the barrier to entry for homeowners who are looking for flexible options but are not familiar with the blockchain or NFTs.

However, launching NFT-based solutions for real estate isn’t straightforward because of several pitfalls. Let’s explore a few key challenges of adopting non-fungible tokens for trading physical property:

Absence of a legal framework. NFTs are still on their way to being fully described within the legal framework in different countries. That’s why potential buyers doubt whether a digital purchase will truly confer legal ownership of a home through all traditional channels. To handle this issue, research how existing projects have managed to implement NFTs in real estate processes. For example, Propy says they managed to wrap their NFTs within the US legal framework by switching the ownership of property from an individual to a US-based legal entity.

Compliance with tax laws. It’s probably fair to say that in the majority of countries, real estate transactions are subject to tax. Using an NFT as a digital representation of property can raise lots of questions on how to deal with taxes in each individual country or state. Roxanne Bland, a contributing editor with Tax Notes, assumes that the US is likely to make NFTs subject to sales tax, so keep an eye on upcoming news and laws to avoid legal issues.

Possibility of a sudden value drop. NFTs are often traded for cryptocurrencies on marketplaces. And the crypto market can have spikes and drops. There’s the potential that a real estate NFT’s value could drop without warning, which might scare away investors.

Little enthusiasm among older generations. Commercial real estate is primarily owned by people of older generations, who are likely to be less enthusiastic about adopting new technology compared to younger generations — at least in the near future. Therefore, real estate businesses who are already considering implementing NFT-related technologies in their services might want to combine this approach with a conventional one in order to address the needs of different client groups.

Possible loss of crypto keys. NFT marketplaces for real estate can ensure secure and transparent transactions. However, there still can be issues on the user side. For example, users can lose the keys to their crypto accounts, which in turn can lead to delays with closing a deal and other issues.

With all this information, let’s move to the technical part and discuss how to develop non-fungible tokens that can power real estate marketplaces.

Read also:
Decentralized Finance (DeFi) Solutions: Benefits, Challenges, and Best Practices to Build One

How to create NFTs for real estate

Below, we show two examples of how you can create an NFT for real estate on the Ethereum and Algorand blockchains. Both platforms support a variety of programming languages, and which language you should choose depends on your project’s specifics. For this article, we use code examples written in Solidity, Python, and JavaScript.

The main differences between these platforms are:

  • For Ethereum, you create an NFT by deploying a smart contract with the minting logic (token creation process) to Ethereum.
  • For Algorand, you only have to write simple JavaScript code and deploy an asset creation transaction using the Algorand SDK.

Let’s explore each case in detail.

Developing NFTs for Ethereum

To create an NFT on Ethereum, you have to complete the following steps:

  1. Connect to the Ethereum blockchain
  2. Create and initialize a project
  3. Write the script for the smart contract
  4. Write the deployment script
  5. Deploy the smart contract

In this article, we only cover the script and deployment steps.

Ethereum supports different programming languages, and for our example, we decided to write a simple smart contract in Solidity using the OpenZeppelin Contracts library:

pragma solidity ^0.8.0;

import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts/utils/Counters.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721URIStorage.sol";

contract MyNFT is ERC721URIStorage, Ownable {
    using Counters for Counters.Counter;
    Counters.Counter private _tokenIds;

    constructor() ERC721("RealEstateNFT", "NFT") {}

    function mintNFT(address recipient, string memory tokenURI)
        public onlyOwner
        returns (uint256)

        uint256 newItemId = _tokenIds.current();
        _mint(recipient, newItemId);
        _setTokenURI(newItemId, tokenURI);
  return newItemId;

As you can see, we created the main function of the contract: mintNFT, which uses some inherited methods. We’ll apply this function later to create a deployment script.

Here is the deployment script written in JavaScript:

async function main() {
  const MyNFT = await ethers.getContractFactory("RealEstateNFT")

  const myNFT = await MyNFT.deploy()
  await myNFT.deployed()
  console.log("Contract deployed to address:", myNFT.address)

You can also use Python for developing the deployment script. Here’s an example of such code:

from web3 import Web3

# using infura provider
provider_url =<your url="">
w3 = Web3(Web3.HTTPProvider(provider_url))

# abi and bytecode are obtained from the contract compilation
RealEstateNFT = w3.eth.contract(abi=abi, bytecode=bytecode)

ropsten_chain = 3
wallet =<your eth="" wallet="">
nonce = w3.getTransactionCount(wallet)

transaction = RealEstateNFT.constructor().buildTransaction(
		“gasPrice”: w3.eth.gas_price,
		“chainId”: ropsten_chain,
from”: wallet,
		“nonce”: nonce,
signed_transaction = w3.eth.account.sign_transaction(transaction,
							    private_key=<your private="" key="">’)
transaction_hash = w3.eth.send_raw_transaction(signed_transaction.rawTransaction)
transaction_receipt = w3.eth.wait_for_transaction_receipt(transaction_hash)

Once you connect to Ethereum and deploy the contract, the platform will show you the contract address so you can connect to the contract and start using it.

Read also:
The Power of Python: Pros and Cons, Integration Capabilities, and Use Cases

Developing NFTs for Algorand

Developing NFTs on the Algorand blockchain differs slightly from doing so on Ethereum.

You don’t need to develop a smart contract to deploy an NFT. Instead, you only need to send a specific transaction to the blockchain. Such an operation doesn’t require many additional tools. You only need access to an environment that can run programs in one of the programming languages supported by Algorand. For our example, we use JavaScript.

Here’s an example of how to create and deploy an Alogrand Standard Asset (ASA) using AlgoSDK — the JavaScript SDK for Algorand:

const algosdk = require(“algosdk”);

async function createAsset(unitName, assetName) {
    // tUse PureStake API to connect to Algorand
    algodclient = new algosdk.Algodv2(
<your api="" token="">’, 
    ); // port field is empty string

    // the addresses that are used don’t actually exist
    let params = await algodclient.getTransactionParams().do();
    let note = undefined; // arbitrary data to be stored in the transaction; here, none is stored
    // Asset creation specific parameters
    // The following parameters are asset-specific
    // These will be reused throughout the example.
    // Whether user accounts will need to be unfrozen before transacting    
    let defaultFrozen = false;
    // integer number of decimals for asset unit calculation
    let decimals = 0;
    // total number of units of this asset available for circulation   
    // as long as we create an NFT the amount is 1
    let totalIssuance = 1;
    // Used to display asset units to user    
    let unitName = "RET";
    // Friendly name of the asset    
    let assetName = "Real Estate Asset";
    // Optional string pointing to a URL relating to the asset
    let assetURL = "http://someurl";
    // Optional hash commitment of some sort relating to the asset. 32-character length.
    let assetMetadataHash = "16efaa3924a6fd9d3a4824799a4ac65d";
    // The following parameters are the only ones
    // that can be changed, and they have to be changed
    // by the current manager
    // Specified address can change reserve, freeze, clawback, and manager
    // Specified address is considered the asset reserve
    // (it has no special privileges and is only informational)
    // Specified address can freeze or unfreeze user asset holdings 
    // Specified address can revoke user asset holdings and send 
    // them to other addresses    

    // signing and sending "txn" allows "addr" to create an asset
    let txn = algosdk.makeAssetCreateTxnWithSuggestedParams(

    let rawSignedTxn = txn.signTxn(“<your secret="" key="">”);
    let tx = (await algodclient.sendRawTransaction(rawSignedTxn).do());
    const ptx = await algosdk.waitForConfirmation(algodclient, tx.txId, 4);
    console.log(ptx); // prints out the transaction info and asset id

// creates a token with corresponding unit and asset names
createAsset(‘RET’, ‘Real Estate Token’);

You can write such code in a JavaScript file and then run it with Node.js. That’s all you need to create a non-fungible token on the Algorand blockchain.

Related services

Blockchain Consulting and Development Services


Non-fungible tokens are still a relatively new concept for many people as well as for governments, who need to create solid legal frameworks for their use.

But despite legal and technical challenges, some real estate companies are already working on minting real estate tokens, developing smart contracts for mortgages, and providing their customers with blockchain-based opportunities to buy, sell, and rent properties. In this way, they attempt to gain a competitive advantage and increase their chances of becoming industry leaders once legal frameworks are finalized.

At Apriorit, we have strong teams of professional blockchain developers who continuously explore new technologies and have vast experience delivering top-notch solutions. When creating IT products, we focus on ensuring the best quality and cybersecurity right from the first stages of development.

Our specialists are ready to help you build flawless solutions such as:

  • Cryptocurrency and NFT marketplaces
  • Smart contracts
  • Real estate NFT platforms

Ready to bring your real estate solution to the next level? Contact us to discuss your project details!

Tell us about your project

Send us a request for proposal! We’ll get back to you with details and estimations.

By clicking Send you give consent to processing your data

Book an Exploratory Call

Do not have any specific task for us in mind but our skills seem interesting?

Get a quick Apriorit intro to better understand our team capabilities.

Book time slot

Contact us