{"id":2839,"date":"2021-01-22T21:09:00","date_gmt":"2021-01-22T08:09:00","guid":{"rendered":"http:\/\/www.talkcrypto.org\/blog\/?p=2839"},"modified":"2021-02-07T23:22:34","modified_gmt":"2021-02-07T10:22:34","slug":"deploy-solidity-helloworld-to-ethereum-testnet","status":"publish","type":"post","link":"https:\/\/www.talkcrypto.org\/blog\/2021\/01\/22\/deploy-solidity-helloworld-to-ethereum-testnet\/","title":{"rendered":"Deploy Solidity helloWorld to Ethereum testnet"},"content":{"rendered":"\n<p>Building on from the previous article on creating a helloWorld smart contract, here we will show how to deploy a contract to an Ethereum testnet. <\/p>\n\n\n\n<p>The testnet we will use is called Ropsten but there are others can you can choose such as Koven, Rinkeby or Goerli. <\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 1: Install Metamask<\/h2>\n\n\n\n<p><a rel=\"noreferrer noopener\" href=\"https:\/\/metamask.io\/\" target=\"_blank\">Metamask<\/a> is a browser plugin that can serve as a crypto wallet and also as a connection to various blockchains to communicate and sign transactions. <\/p>\n\n\n\n<p>Install this by visiting: https:\/\/metamask.io\/download.html<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 2: Change the Metamask network<\/h2>\n\n\n\n<p>Change the network to the <a rel=\"noreferrer noopener\" href=\"https:\/\/www.springworks.in\/blog\/how-to-connect-metamask-to-the-ropsten-test-network\/\" target=\"_blank\">Ropsten<\/a> testnet.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large is-resized\"><img fetchpriority=\"high\" decoding=\"async\" src=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/image-1.png\" alt=\"\" class=\"wp-image-2840\" width=\"267\" height=\"271\" srcset=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/image-1.png 696w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/image-1-296x300.png 296w\" sizes=\"(max-width: 267px) 100vw, 267px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Step 3: Get some test ether<\/h2>\n\n\n\n<p>To get some test ether, click buy, and then click Get Ether in the Test Faucet section below.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large is-resized\"><img decoding=\"async\" src=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/image-2-608x1024.png\" alt=\"\" class=\"wp-image-2841\" width=\"281\" height=\"472\" srcset=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/image-2-608x1024.png 608w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/image-2-178x300.png 178w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/image-2.png 682w\" sizes=\"(max-width: 281px) 100vw, 281px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Step 4: Deploy your smart contract<\/h2>\n\n\n\n<p>Change your environment from Javascript VM to Injected Web3. <\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"432\" src=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.51.41-pm-1024x432.png\" alt=\"\" class=\"wp-image-2843\" srcset=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.51.41-pm-1024x432.png 1024w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.51.41-pm-300x127.png 300w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.51.41-pm-768x324.png 768w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.51.41-pm.png 1288w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Now when you click deploy, Metamask will pop up and ask you to confirm the transaction. <\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"604\" src=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.59.36-pm-1024x604.png\" alt=\"\" class=\"wp-image-2844\" srcset=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.59.36-pm-1024x604.png 1024w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.59.36-pm-300x177.png 300w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.59.36-pm-768x453.png 768w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.59.36-pm-1536x906.png 1536w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-6.59.36-pm-2048x1208.png 2048w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Click confirm. <\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 5: Interacting with your smart contract<\/h2>\n\n\n\n<p>Now you can interact with your smart contract the same way but each time you try and store a message, you will have to pay a small fee (gas) and sign the transaction using Metamask. <\/p>\n\n\n\n<p>Here is a link to the smart contract: https:\/\/ropsten.etherscan.io\/address\/0xa0aa7eb1055dccee55df798cd70cc1766322bf85<\/p>\n\n\n\n<p>and here is a link to the transaction where you can see the string that was stored.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"999\" height=\"878\" src=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-7.08.18-pm.png\" alt=\"\" class=\"wp-image-2845\" srcset=\"https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-7.08.18-pm.png 999w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-7.08.18-pm-300x264.png 300w, https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/Screen-Shot-2021-01-22-at-7.08.18-pm-768x675.png 768w\" sizes=\"(max-width: 999px) 100vw, 999px\" \/><\/figure>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Building on from the previous article on creating a helloWorld<\/p>\n","protected":false},"author":1,"featured_media":2847,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,2],"tags":[],"class_list":["post-2839","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-ethereum","category-smart-contracts"],"featured_image_urls":{"full":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false],"thumbnail":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask-150x150.jpg",150,150,true],"medium":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false],"medium_large":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false],"large":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false],"1536x1536":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false],"2048x2048":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false],"chromenews-featured":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false],"chromenews-large":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false],"chromenews-medium":["https:\/\/www.talkcrypto.org\/blog\/wp-content\/uploads\/2021\/01\/metamask.jpg",194,180,false]},"author_info":{"info":["seandotau"]},"category_info":"<a href=\"https:\/\/www.talkcrypto.org\/blog\/category\/ethereum\/\" rel=\"category tag\">Ethereum<\/a> <a href=\"https:\/\/www.talkcrypto.org\/blog\/category\/smart-contracts\/\" rel=\"category tag\">Smart Contracts<\/a>","tag_info":"Smart Contracts","comment_count":"0","_links":{"self":[{"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/posts\/2839","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/comments?post=2839"}],"version-history":[{"count":1,"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/posts\/2839\/revisions"}],"predecessor-version":[{"id":2846,"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/posts\/2839\/revisions\/2846"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/media\/2847"}],"wp:attachment":[{"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/media?parent=2839"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/categories?post=2839"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.talkcrypto.org\/blog\/wp-json\/wp\/v2\/tags?post=2839"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}