Ethereum : Raw Transaction Creation and Signing

Ethereum is often described as “the world computer.”
You are executing transactions and changing the state of the Ethereum blockchain when you communicate with it.

Have you ever wondered what happens when you perform an Ethereum transaction?Let’s look at an example transaction and see if we can grasp it.


Using the ethereumjs-tx library, we’ll create a raw transaction and sign it.

Let’s look at each field in the raw transaction object to see how they’re set.

nonce : Each Ethereum account has a field called nonce to keep track of the total number of transactions that account has executed.

gasPrice : Price per unit of gas you are willing to pay for this transaction.

gasLimit: Maximum gas you are willing to pay for this transaction.

to: The address to which you are directing this function call.

value: Total Ether you want to send.

data : The message field.

Full code


Your geth/parity node broadcasts the signed transaction to its peers, who then broadcast to their peers, and so on.Your local node also outputs the transaction id until the transaction is broadcast to the network, which you can use to monitor the status of your transaction.The hash of the signed transaction object is used as the transaction id.

transactionId = sha3(serializedTx)




Blockchain Developer and Educator

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

OEC Podcast, 0xTalks, Invites CryptoBlades CEO to the Show

You never know what’s just ‘round the corner. #morningwalk

PAXG: Bringing gold to ZebPay

PAXG: Bringing gold to ZebPay

MyWish has been recognized as one of the Top Blockchain Development Companies by DesignRush

Top blockchain development company mywish by designrush

Identity done right, onchain & off

Recapitulation of Norse Finance AMA event held at AMA LOVERS CLUB

How Tokenization is Transforming Real Estate on the Blockchain

#davidhockney #londongallery #contemporaryart

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Abhilash Sreedharan

Abhilash Sreedharan

Blockchain Developer and Educator

More from Medium

Neon: A Gateway from Ethereum to Solana

Sphynx Network Integrates Chainlink VRF to Help Randomize NFTs and Gameplay

Breaking News: On February 15, Hotpot will be officially deployed on Polygon!

Why Durafi Fund Tokens Are Better than Crypto Index Funds