2

I created a wallet account(ethereum) using web3.personal.newAccount('password'). Now, this method generally returns the address of new account, however, to send transactions from that account I would also need a private key. Can anyone please help from where I can get that?

Thanks in advance!

1 Answer 1

1

If you want to send transactions from within geth, just type personal.unlockAccount(address) and then send transactions.

If you need the actual private key from outside geth, you can find the JSON file with all necessary information to retrieve the private key at the same directory as the ipc was started when you started geth (typically .ethereum if working in the main network), under keystore/

With this JSON file, you can import it in many wallets, or in metamask, and start sending transactions.

If you need the actual plaintext private key for raw signing or whatever you need it, load up the file to myetherwallet.com. I am aware of another way of manually decipher from within geth but I can not find it at the moment.

2
  • Thanks for your reply. Actually, I am using testrpc instead of geth and I am unable to locate the keystore. Can you please help me in this regard.
    – Ravi Verma
    Dec 26, 2017 at 7:53
  • If you are using ubantu os in home directory .ethereum file is hidden just view in your hidden files.
    – rahul_eth
    May 9, 2018 at 19:06

Your Answer

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

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