{"id":297,"date":"2022-09-12T23:01:32","date_gmt":"2022-09-12T21:01:32","guid":{"rendered":"https:\/\/ackeeblockchain.com\/blog\/?post_type=glossary&#038;p=297"},"modified":"2022-09-12T23:01:32","modified_gmt":"2022-09-12T21:01:32","slug":"gas-optimization","status":"publish","type":"glossary","link":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/","title":{"rendered":"Gas optimization"},"content":{"rendered":"<p class=\"p1\">Gas is a <b>transaction fee<\/b> on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.<\/p>\n<p class=\"p1\">Gas is <b>expensive<\/b>. It is in our best interest to create contracts as gas efficient as possible without breaching security.<\/p>\n<p class=\"p1\"><b>Gas optimizations<\/b> refer to:<\/p>\n<ul class=\"ul1\">\n<li class=\"li1\">doing what is cheap and avoiding what is expensive in terms of gas costs on EVM blockchains;<\/li>\n<li class=\"li1\">doing what needs to be done as cheaply as possible.<\/li>\n<\/ul>\n<p class=\"p1\"><span class=\"s1\"><a href=\"https:\/\/mudit.blog\/solidity-gas-optimization-tips\/\">This blog post<\/a><\/span> shows a few basic gas optimization tips for those interested.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction. Gas is expensive. It is in our best interest to create contracts as gas efficient as possible without breaching security. Gas optimizations refer to: doing what is cheap and avoiding&hellip;<\/p>\n","protected":false},"author":12,"featured_media":0,"parent":0,"template":"","glossary-cat":[],"class_list":["post-297","glossary","type-glossary","status-publish","hentry"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 4.9.8 - aioseo.com -->\n\t<meta name=\"description\" content=\"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Jan \u0160mol\u00edk\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 4.9.8\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"Ackee Blockchain - Blog &amp; Research\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"Gas optimization - Ackee Blockchain\" \/>\n\t\t<meta property=\"og:description\" content=\"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/\" \/>\n\t\t<meta property=\"og:image\" content=\"https:\/\/ackee.xyz\/blog\/wp-content\/uploads\/2023\/02\/cropped-ABCH_Logo_blue-black.png\" \/>\n\t\t<meta property=\"og:image:secure_url\" content=\"https:\/\/ackee.xyz\/blog\/wp-content\/uploads\/2023\/02\/cropped-ABCH_Logo_blue-black.png\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2022-09-12T21:01:32+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2022-09-12T21:01:32+00:00\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Gas optimization - Ackee Blockchain\" \/>\n\t\t<meta name=\"twitter:description\" content=\"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.\" \/>\n\t\t<meta name=\"twitter:image\" content=\"https:\/\/ackee.xyz\/blog\/wp-content\/uploads\/2023\/02\/cropped-ABCH_Logo_blue-black.png\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/ackee.xyz\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/#listItem\",\"name\":\"Glossary Terms\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/#listItem\",\"position\":2,\"name\":\"Glossary Terms\",\"item\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/#listItem\",\"name\":\"Gas optimization\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/#listItem\",\"position\":3,\"name\":\"Gas optimization\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/#listItem\",\"name\":\"Glossary Terms\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/#organization\",\"name\":\"Ackee Blockchain\",\"description\":\"Blog & Research\",\"url\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/02\\\/cropped-ABCH_Logo_blue-black.png\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/#organizationLogo\",\"width\":5268,\"height\":825},\"image\":{\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/#organizationLogo\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/author\\\/jan-smolik\\\/#author\",\"url\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/author\\\/jan-smolik\\\/\",\"name\":\"Jan \\u0160mol\\u00edk\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/#authorImage\",\"url\":\"https:\\\/\\\/abchprod.wpengine.com\\\/wp-content\\\/uploads\\\/2024\\\/08\\\/Frame-318-1-96x96.png\",\"width\":96,\"height\":96,\"caption\":\"Jan \\u0160mol\\u00edk\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/#webpage\",\"url\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/\",\"name\":\"Gas optimization - Ackee Blockchain\",\"description\":\"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/glossary\\\/gas-optimization\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/author\\\/jan-smolik\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/author\\\/jan-smolik\\\/#author\"},\"datePublished\":\"2022-09-12T23:01:32+02:00\",\"dateModified\":\"2022-09-12T23:01:32+02:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/\",\"name\":\"Ackee Blockchain\",\"description\":\"Blog & Research\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/ackee.xyz\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Gas optimization - Ackee Blockchain","description":"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.","canonical_url":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"BreadcrumbList","@id":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/ackee.xyz\/blog#listItem","position":1,"name":"Home","item":"https:\/\/ackee.xyz\/blog","nextItem":{"@type":"ListItem","@id":"https:\/\/ackee.xyz\/blog\/glossary\/#listItem","name":"Glossary Terms"}},{"@type":"ListItem","@id":"https:\/\/ackee.xyz\/blog\/glossary\/#listItem","position":2,"name":"Glossary Terms","item":"https:\/\/ackee.xyz\/blog\/glossary\/","nextItem":{"@type":"ListItem","@id":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/#listItem","name":"Gas optimization"},"previousItem":{"@type":"ListItem","@id":"https:\/\/ackee.xyz\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/#listItem","position":3,"name":"Gas optimization","previousItem":{"@type":"ListItem","@id":"https:\/\/ackee.xyz\/blog\/glossary\/#listItem","name":"Glossary Terms"}}]},{"@type":"Organization","@id":"https:\/\/ackee.xyz\/blog\/#organization","name":"Ackee Blockchain","description":"Blog & Research","url":"https:\/\/ackee.xyz\/blog\/","logo":{"@type":"ImageObject","url":"https:\/\/ackee.xyz\/blog\/wp-content\/uploads\/2023\/02\/cropped-ABCH_Logo_blue-black.png","@id":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/#organizationLogo","width":5268,"height":825},"image":{"@id":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/#organizationLogo"}},{"@type":"Person","@id":"https:\/\/ackee.xyz\/blog\/author\/jan-smolik\/#author","url":"https:\/\/ackee.xyz\/blog\/author\/jan-smolik\/","name":"Jan \u0160mol\u00edk","image":{"@type":"ImageObject","@id":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/#authorImage","url":"https:\/\/abchprod.wpengine.com\/wp-content\/uploads\/2024\/08\/Frame-318-1-96x96.png","width":96,"height":96,"caption":"Jan \u0160mol\u00edk"}},{"@type":"WebPage","@id":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/#webpage","url":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/","name":"Gas optimization - Ackee Blockchain","description":"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/ackee.xyz\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/#breadcrumblist"},"author":{"@id":"https:\/\/ackee.xyz\/blog\/author\/jan-smolik\/#author"},"creator":{"@id":"https:\/\/ackee.xyz\/blog\/author\/jan-smolik\/#author"},"datePublished":"2022-09-12T23:01:32+02:00","dateModified":"2022-09-12T23:01:32+02:00"},{"@type":"WebSite","@id":"https:\/\/ackee.xyz\/blog\/#website","url":"https:\/\/ackee.xyz\/blog\/","name":"Ackee Blockchain","description":"Blog & Research","inLanguage":"en-US","publisher":{"@id":"https:\/\/ackee.xyz\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"Ackee Blockchain - Blog &amp; Research","og:type":"article","og:title":"Gas optimization - Ackee Blockchain","og:description":"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.","og:url":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/","og:image":"https:\/\/ackee.xyz\/blog\/wp-content\/uploads\/2023\/02\/cropped-ABCH_Logo_blue-black.png","og:image:secure_url":"https:\/\/ackee.xyz\/blog\/wp-content\/uploads\/2023\/02\/cropped-ABCH_Logo_blue-black.png","article:published_time":"2022-09-12T21:01:32+00:00","article:modified_time":"2022-09-12T21:01:32+00:00","twitter:card":"summary","twitter:title":"Gas optimization - Ackee Blockchain","twitter:description":"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.","twitter:image":"https:\/\/ackee.xyz\/blog\/wp-content\/uploads\/2023\/02\/cropped-ABCH_Logo_blue-black.png"},"aioseo_meta_data":{"post_id":"297","title":null,"description":"Gas is a transaction fee on the Ethereum blockchain; every time a transaction gets sent to the blockchain, a gas fee must be paid for the computational resources used by the transaction.","keywords":[],"keyphrases":{"focus":{"keyphrase":"","score":0,"analysis":{"keyphraseInTitle":{"score":0,"maxScore":9,"error":1}}},"additional":[]},"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":"","og_custom_url":null,"og_article_section":null,"og_article_tags":[],"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[],"defaultGraph":"WebPage","defaultPostTypeGraph":""},"schema_type":"default","schema_type_options":"{\"article\":{\"articleType\":\"BlogPosting\"},\"course\":{\"name\":\"\",\"description\":\"\",\"provider\":\"\"},\"faq\":{\"pages\":[]},\"product\":{\"reviews\":[]},\"recipe\":{\"ingredients\":[],\"instructions\":[],\"keywords\":[]},\"software\":{\"reviews\":[],\"operatingSystems\":[]},\"webPage\":{\"webPageType\":\"WebPage\"},\"blockGraphs\":[]}","pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":"-1","robots_max_videopreview":"-1","robots_max_imagepreview":"large","priority":null,"frequency":"default","local_seo":null,"limit_modified_date":false,"ai":null,"created":"2022-09-12 21:01:32","updated":"2022-09-13 22:10:58","breadcrumb_settings":null,"seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/ackee.xyz\/blog\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/ackee.xyz\/blog\/glossary\/\" title=\"Glossary Terms\">Glossary Terms<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tGas optimization\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/ackee.xyz\/blog"},{"label":"Glossary Terms","link":"https:\/\/ackee.xyz\/blog\/glossary\/"},{"label":"Gas optimization","link":"https:\/\/ackee.xyz\/blog\/glossary\/gas-optimization\/"}],"_links":{"self":[{"href":"https:\/\/ackee.xyz\/blog\/wp-json\/wp\/v2\/glossary\/297","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ackee.xyz\/blog\/wp-json\/wp\/v2\/glossary"}],"about":[{"href":"https:\/\/ackee.xyz\/blog\/wp-json\/wp\/v2\/types\/glossary"}],"author":[{"embeddable":true,"href":"https:\/\/ackee.xyz\/blog\/wp-json\/wp\/v2\/users\/12"}],"version-history":[{"count":0,"href":"https:\/\/ackee.xyz\/blog\/wp-json\/wp\/v2\/glossary\/297\/revisions"}],"wp:attachment":[{"href":"https:\/\/ackee.xyz\/blog\/wp-json\/wp\/v2\/media?parent=297"}],"wp:term":[{"taxonomy":"glossary-cat","embeddable":true,"href":"https:\/\/ackee.xyz\/blog\/wp-json\/wp\/v2\/glossary-cat?post=297"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}