Is it possible to transfer ETH with Node.js without writing a smart contract?

Hello everyone,

I am learning a lot by developing smart contracts with open zeppelin, truffle, and ganache. Let’s say a user wants to transfer ETH from his account to another account using Metamask (just like someone would pay for a service). I would like to use Node.js for that. Is that possible? (Perhaps with web3 or other library)

My first idea was to write a smart contract that could handle the payments, but the contract is rather simple since it doesn’t store anything and only handles payments, so I thought I’d be a bit overkill for this purpose.

Thanks a lot!

Yes it is definitely overkill. You can send transactions with ETH by using the Web3.js library. See web3.eth.sendTransaction.

1 Like