The “decentralized” element in dapps

Let’s start with the basics. In order to explain how exactly applications can be decentralized and what it means, we should start with the very reason we’re even having this conversation, which is blockchain technology.

One of the key characteristics of blockchain is decentralization, which means that there is no central server that everyone needs to connect to. Instead, computers connect on P2P (peer-to-peer) principle. It is a basis for blockchain's fundamental values, which are better transparency and no authoritarian control within the network. Other advantages include better security, data integrity, and more. But, let’s get back to the topic of the day.

Decentralized apps are applications within the blockchain, so it’s fair to say that they inherit decentralization as a foundation of their existence. Every process performed by a decentralized application happens on the specific blockchain that it was deployed on, such as Ethereum or Polkadot, as opposed to some dedicated server. So, in the case of Ethereum, dapp instructions are performed by the EVM (Ethereum Virtual Machine), which can be described as a single entity supported by thousands of computers that run the EVM client.

But, what does it mean for decentralized applications?

Three basic things you should know about dapps

1. Once it’s deployed on the blockchain, the source code for the dapp is public

All blockchain users can see every dapp (and its source code) and use it. But because this is the case, they need to be appropriately secured. Any potential vulnerability might be exploited by hackers and result in the emptying of the dapp’s account.


2. They are all based on smart contracts

My colleague, Jakub Czachura, explained in detail what smart contracts are in his blog post, so I’ll keep it short this time by quoting him:

“A smart contract is a publicly available piece of software and data written into a blockchain. It executes an action after certain conditions are met.

Every decentralized app is built using such smart contracts, and, at this point, most of them are written in a language specifically designed for this purpose - Solidity (on Ethereum blockchain). However, there are other options, such as Javascript and Rust.

3. Dapps need fuel to run (and fuel isn’t cheap)

Every process performed by a decentralized app involves a cost. Even if a given dapp doesn’t have a specific fee for its usage, a user must pay a gas price, which is a fee for the computing energy required for that transaction or process. The actual price depends on the current network load. Because of it, many dapp projects turn out to be unprofitable. You can read more about it here.

What are the technological and business advantages of dapps?

Before I move to the actual upsides, I should say that the use of blockchain or dapps definitely isn’t a perfect solution for every project, purpose, or industry. Contrary to what many people think, it won’t make you a dinosaur if you’re not implementing blockchain in your business. In most cases, it’s simply unnecessary. You can read more about the topic in the article “Do I need blockchain in my project?” by our business development expert, Krzysztof Waliński.

On the other hand, there truly are dozens of fascinating dapp examples that utilize blockchain in the right way. So, what aspects are so crucial for developers that they choose to make a dapp instead of a regular application?

The lack of censorship and the public nature of blockchain

Whatever gets implemented on blockchain, will stay there forever. It’s publicly available and open for analysis and inspiration, so developers can freely learn from other projects after they’re deployed. That’s a fantastic advantage for devs who want to see how things work from the inside and learn from others before they make the same mistakes.

Of course, it works the same way from the business perspective. The public availability of every deployed dapp makes it super easy to analyze the work of others and even copy some of the solutions for your own application. It happened before with Sushiswap (DEX) and Uniswap V2, and it will happen again. Even the most brilliant dapp can be copied, modified, and deployed again under a different brand. Of course, it doesn’t guarantee success, but it definitely facilitates improvement and increases competitiveness.

It’s also worth mentioning that not only dapps are publicly available, but all operations on them are as well. So each time someone uses a dapp, the information about it is available for all blockchain users. It might be considered a lack of privacy, but at the same time, it’s what enables blockchains to keep perfect integrity and stay decentralized.

Stability

The term server downtime practically doesn’t exist in the vocabulary of a blockchain developer. Because blockchain is decentralized and runs simultaneously on many computers, it would take a massive global outage to turn it off, so it’s virtually impossible. That’s why dapps don’t go down like many of your favorite websites, streaming services, and social media platforms.

Other crucial aspects of decentralized apps and their future

Flexibility and scalability

Those two things have been widely discussed in dapp development for quite some time. Scalability, in particular, has been a challenging issue due to high demand and skyrocketing gas prices on Ethereum. In simple words, it’s been very tough to build large applications for armies of users because the more traffic there is, the more expensive the gas fee becomes. However, there is a long-awaited change on Ethereum that’s supposed to change the consensus mechanism from Proof of Work (PoW) to Proof of Stake (PoS). The goal is to reduce gas prices and effectively CO2 emissions from mining.

Flexibility also isn’t exactly the biggest advantage in dapp development. In order to implement changes to an existing smart contract, we need to deploy a new one and pay a total gas price for that process. If we had funds or data on a previous one, we need to transfer it to a new one too, so it’s best to keep redeployments to as few as possible.

Cost of dapp development

Right now, it’s far more expensive to build decentralized apps than regular ones. It’s mainly because very few available developers know blockchain and how to write smart contracts. And even if they know their way around smart contracts, writing secure dapps require a deep knowledge of cryptography and the latest security trends on the blockchain. The security aspect is incredibly crucial. Because the dapp’s code is public, even the tiniest mistake can allow someone to steal all funds from the smart contract, so that’s another reason why experienced blockchain developers are expensive and hard to come by.

On which blockchains can dapps be deployed?

The first blockchain that introduced smart contracts was Ethereum. It was one of the main reasons for the rapid rise in popularity of ETH. Since then, more and more developers have taken inspiration and begun similar projects.

Ethereum - here’s where it all started and still starts for most businesses and developers interested in smart contracts and decentralized apps. One of the critical values of Ethereum at this point is the large and supportive community, which significantly facilitates the development of new solutions.

EOS - the blockchain is considered to be the biggest rival of Ethereum. It already has PoS, better efficiency, and allows dapp deployment in Solidity, exactly as its competitor.

Tron - started in 2018, it’s often compared to Ethereum because of many similarities. However, Tron already introduced the PoS consensus, which is still a work in progress for the older brother. As a result, transactions on Tron are free.

EON - thanks to using DPOS (delegated Proof of Stake) consensus, it allows 4000 transactions every 3 minutes, which is an impressive result. Right now, only the EON development team is allowed to implement so-called “smart transactions” because, as they claim, they want to avoid spamming by users. As a result, its development isn’t as rapid as with more liberal blockchains. Still, it’s a situation worth keeping an eye on.

Three dapp examples that couldn’t exist without blockchain

1. DeFi as a whole

The decentralization of blockchains means that networks can function perfectly independently from any state or corporate authorities. Cryptocurrencies or tokens won’t ever be introduced to centralized systems. Each transaction is public, and the ownership of perfectly clear for everyone without the need for paperwork or the involvement of any type of authorities. The opportunities it brings are enormous.

2. Steem

Steem is a platform that allows content creators to easily earn money without tons of paperwork and overhead costs that would otherwise make the entire idea impossible (both for content creators and Steem devs). The way Steem works is simple. You make good content; you get tokens.

3. NFT-based games and platforms

The whole premise of NFT is to create digital tokens that are impossible to duplicate, and that alone is only possible thanks to blockchain. While motives behind creating them are often questionable, NFTs are probably the most widespread application of blockchain, other than cryptocurrencies. The non-fungible tokens are created by artists, sports organizations, influencers, and much more. Moreover, there are entire games based on NFTs as in-game items and skins. You can read more about them in another article by Jakub: What is NFT technology?

Future applications can also include dapps for voting. The use of blockchain could guarantee that there is no chance that one person’s vote would be manipulated, changed, or counted twice.

What does it take to write a decentralized app?

The minimum package includes:

  • basic knowledge about a blockchain on which you wish to deploy it
  • proficiency in Solidity or some other language for smart contracts
  • cryptography skills
  • front-end framework of choice

But if you want the real deal, Krzysztof Fonał already answered this question very thoroughly in his article “Getting started: Ethereum smart contracts”, in which he explained step-by-step how to create a token.

Let’s build a dapp together

As a team of blockchain developers and enthusiasts, we’re always ready to hear about a new exciting dapp idea. If you have one of them up your sleeve, arrange a call with us, and we’ll help you figure out the best way forward.