I am thinking of making a webapp where I have to save some private data and other data that could be public. For simplicity let's say it's a quizzes page but it logs in with Metamask.

We are going to have to make some smart contracts for some functionality.

My question is which stack is recommended.

I was learning nodejs to develop an api that the front communicates with.

We are going to use React & ethers.js in frontend. But I'm not sure what to do with the backend and what database to use.

Would it be okay to use MongoDB for everything? I would like the webapp to be as decentralized as possible.

I get lost in the part of how to connect everything, for example how to connect the metamask log in with the database, or the smart contracts and that, etc.

I don't know what I could use as a database if I want to make it as decentralized as possible.

I also don't know nodejs is ok, or if I use solidity for everything


1 Answer 1


first of all: welcome to the SE community!

Second of all, I think your question is not asked in the right place :) Your question is relatively general and not related to Ethereum.

I have to admit it looks like you are getting a bit ahead of yourself. You want to do a lot, but it seems like you need a little more experience. It would be great if you would ask your question () again after you have a little more general programming experience.

Now to your question: The simplest answer is to use the stack you are most comfortable using. If you like node.js, use node.js. If you like NoSQL DBs use them, otherwise use RDBMS, doesn't matter.

In almost all cases it doesn't make any sense to create a decentralized web app. This would probably create more downsides than advantages, especially for a new programmer (updating is harder, loading times are usually longer, etc). Also, there are a lot of concepts you need to get right first (You cannot connect Metamask to your DB, first fully understand client-server architecture).

Now if you really want a decentralized DB, gun.js is one. Otherwise I can only recommend that you start with a boilerplate like: https://github.com/NomicFoundation/hardhat-hackathon-boilerplate when you use hardhat, or https://trufflesuite.com/boxes/drizzle/ if you prefer truffle.

I wish you the best on your programming journey!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.