{"id":18917,"date":"2021-02-14T13:32:45","date_gmt":"2021-02-14T11:32:45","guid":{"rendered":"https:\/\/elementor.com\/help\/?p=18917"},"modified":"2024-01-14T16:04:04","modified_gmt":"2024-01-14T14:04:04","slug":"code-highlight-pro","status":"publish","type":"post","link":"https:\/\/elementor.com\/help\/code-highlight-pro\/","title":{"rendered":"Code Highlight widget"},"content":{"rendered":"\n<p>Elementor\u2019s Code Highlight widget enables you to use syntax highlighting to present code examples in a readable, easy to copy format.<\/p>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe title=\"How to Use Elementor Code Highlight Widget [PRO]\" width=\"800\" height=\"450\" src=\"https:\/\/www.youtube.com\/embed\/mV0wNM8FlKI?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Language<\/strong>: Select your coding language to properly highlight your code\u2019s syntax. Options include 50+ of supported languages such as Markup, HTML, XML, SVG, Mathml, CSS, Javascript, ActionScript, PHP, Ruby, etc<\/li>\n\n\n\n<li><strong>Code<\/strong>: Enter the snippet of code that you wish to display on the page in the field. This may also use <a href=\"https:\/\/elementor.com\/help\/dynamic-tags-pro\/\">Dynamic Tag<\/a> data from ACF or other plugins <\/li>\n\n\n\n<li><strong>Line Numbers<\/strong>: Choose <strong>Show<\/strong> to display line numbers next to each line<\/li>\n\n\n\n<li><strong>Copy to Clipboard<\/strong>: Choose <strong>Show<\/strong> to allow users to copy the code with a single click on the Copy button in the upper right corner of the code box<\/li>\n\n\n\n<li><strong>Highlight Lines<\/strong>: Designate one or more lines to be highlighted by entering a value or using a <a href=\"https:\/\/elementor.com\/help\/dynamic-tags-pro\/\">Dynamic Tag<\/a>. Sets of numbers should be separated by a comma. (e.g. 2-7, 10, 13-15 would highlight lines 2 through 7, line 10, and lines 13 through 15.)<\/li>\n\n\n\n<li><strong>Word Wrap<\/strong>: Toggle to Show\/Hide word wrapping<\/li>\n\n\n\n<li><strong>Theme<\/strong>: Select a theme for the code display. Both light and dark themes are available to choose from<\/li>\n\n\n\n<li><strong>Height<\/strong>: Enter a height for the code box<\/li>\n\n\n\n<li><strong>Font Size<\/strong>: Set your code\u2019s font size<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>Elementor\u2019s Code Highlight widget enables you to use syntax highlighting to present code examples in a readable, easy to copy format.<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_elementor_kustomer_id":["65a3e9d4f312e0022011b420"],"footnotes":""},"categories":[1439],"tags":[1389,1388,1387,1390,1398,1235],"class_list":["post-18917","post","type-post","status-publish","format-standard","hentry","category-basic-functionality","tag-advanced","tag-agency","tag-essential","tag-expert","tag-legacy-essential","tag-pro"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Code Highlight widget | Elementor<\/title>\n<meta name=\"description\" content=\"Learn everything about Code Highlight widget in this article from Elementor&#039;s Knowledge Base. Get Elementor tips &amp; more.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/elementor.com\/help\/code-highlight-pro\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Code Highlight widget | Elementor\" \/>\n<meta property=\"og:description\" content=\"Learn everything about Code Highlight widget in this article from Elementor&#039;s Knowledge Base. Get Elementor tips &amp; more.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/elementor.com\/help\/code-highlight-pro\/\" \/>\n<meta property=\"og:site_name\" content=\"Help\" \/>\n<meta property=\"article:published_time\" content=\"2021-02-14T11:32:45+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-01-14T14:04:04+00:00\" \/>\n<meta name=\"author\" content=\"Alan Kaler\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alan Kaler\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/elementor.com\/help\/code-highlight-pro\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/elementor.com\/help\/code-highlight-pro\/\"},\"author\":{\"name\":\"Alan Kaler\",\"@id\":\"https:\/\/elementor.com\/help\/#\/schema\/person\/ebf805be1a1abdd587d4b97e3328f430\"},\"headline\":\"Code Highlight widget\",\"datePublished\":\"2021-02-14T11:32:45+00:00\",\"dateModified\":\"2024-01-14T14:04:04+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/elementor.com\/help\/code-highlight-pro\/\"},\"wordCount\":213,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/elementor.com\/help\/#organization\"},\"keywords\":[\"Advanced\",\"Agency\",\"Essential\",\"Expert\",\"Legacy Essential\",\"Pro\"],\"articleSection\":[\"Basic functionality\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/elementor.com\/help\/code-highlight-pro\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/elementor.com\/help\/code-highlight-pro\/\",\"url\":\"https:\/\/elementor.com\/help\/code-highlight-pro\/\",\"name\":\"Code Highlight widget | Elementor\",\"isPartOf\":{\"@id\":\"https:\/\/elementor.com\/help\/#website\"},\"datePublished\":\"2021-02-14T11:32:45+00:00\",\"dateModified\":\"2024-01-14T14:04:04+00:00\",\"description\":\"Learn everything about Code Highlight widget in this article from Elementor's Knowledge Base. Get Elementor tips & more.\",\"breadcrumb\":{\"@id\":\"https:\/\/elementor.com\/help\/code-highlight-pro\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/elementor.com\/help\/code-highlight-pro\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/elementor.com\/help\/code-highlight-pro\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Help Center\",\"item\":\"https:\/\/elementor.com\/help\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Elementor Editor\",\"item\":\"https:\/\/elementor.com\/help\/elementor-editor\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Widgets\",\"item\":\"https:\/\/elementor.com\/help\/elementor-editor\/widgets\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Basic functionality\",\"item\":\"https:\/\/elementor.com\/help\/elementor-editor\/widgets\/basic-functionality\/\"},{\"@type\":\"ListItem\",\"position\":5,\"name\":\"Code Highlight widget\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/elementor.com\/help\/#website\",\"url\":\"https:\/\/elementor.com\/help\/\",\"name\":\"Elementor\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/elementor.com\/help\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/elementor.com\/help\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/elementor.com\/help\/#organization\",\"name\":\"Elementor\",\"url\":\"https:\/\/elementor.com\/help\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/elementor.com\/help\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/elementor.com\/help\/wp-content\/uploads\/2025\/06\/images.png\",\"contentUrl\":\"https:\/\/elementor.com\/help\/wp-content\/uploads\/2025\/06\/images.png\",\"width\":225,\"height\":225,\"caption\":\"Elementor\"},\"image\":{\"@id\":\"https:\/\/elementor.com\/help\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/elementor.com\/help\/#\/schema\/person\/ebf805be1a1abdd587d4b97e3328f430\",\"name\":\"Alan Kaler\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/elementor.com\/help\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/7618989d1401c38afe50748601d8dad91fdb8930f53fe037881768b15ab4b108?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/7618989d1401c38afe50748601d8dad91fdb8930f53fe037881768b15ab4b108?s=96&d=mm&r=g\",\"caption\":\"Alan Kaler\"},\"description\":\"Alan Kaler is an expert Elementorist at Elementor and a WordPress Magician who thinks that the three most beautiful words in our language are: I told you\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Code Highlight widget | Elementor","description":"Learn everything about Code Highlight widget in this article from Elementor's Knowledge Base. Get Elementor tips & more.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/elementor.com\/help\/code-highlight-pro\/","og_locale":"en_US","og_type":"article","og_title":"Code Highlight widget | Elementor","og_description":"Learn everything about Code Highlight widget in this article from Elementor's Knowledge Base. Get Elementor tips & more.","og_url":"https:\/\/elementor.com\/help\/code-highlight-pro\/","og_site_name":"Help","article_published_time":"2021-02-14T11:32:45+00:00","article_modified_time":"2024-01-14T14:04:04+00:00","author":"Alan Kaler","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Alan Kaler","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/elementor.com\/help\/code-highlight-pro\/#article","isPartOf":{"@id":"https:\/\/elementor.com\/help\/code-highlight-pro\/"},"author":{"name":"Alan Kaler","@id":"https:\/\/elementor.com\/help\/#\/schema\/person\/ebf805be1a1abdd587d4b97e3328f430"},"headline":"Code Highlight widget","datePublished":"2021-02-14T11:32:45+00:00","dateModified":"2024-01-14T14:04:04+00:00","mainEntityOfPage":{"@id":"https:\/\/elementor.com\/help\/code-highlight-pro\/"},"wordCount":213,"commentCount":0,"publisher":{"@id":"https:\/\/elementor.com\/help\/#organization"},"keywords":["Advanced","Agency","Essential","Expert","Legacy Essential","Pro"],"articleSection":["Basic functionality"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/elementor.com\/help\/code-highlight-pro\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/elementor.com\/help\/code-highlight-pro\/","url":"https:\/\/elementor.com\/help\/code-highlight-pro\/","name":"Code Highlight widget | Elementor","isPartOf":{"@id":"https:\/\/elementor.com\/help\/#website"},"datePublished":"2021-02-14T11:32:45+00:00","dateModified":"2024-01-14T14:04:04+00:00","description":"Learn everything about Code Highlight widget in this article from Elementor's Knowledge Base. Get Elementor tips & more.","breadcrumb":{"@id":"https:\/\/elementor.com\/help\/code-highlight-pro\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/elementor.com\/help\/code-highlight-pro\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/elementor.com\/help\/code-highlight-pro\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Help Center","item":"https:\/\/elementor.com\/help\/"},{"@type":"ListItem","position":2,"name":"Elementor Editor","item":"https:\/\/elementor.com\/help\/elementor-editor\/"},{"@type":"ListItem","position":3,"name":"Widgets","item":"https:\/\/elementor.com\/help\/elementor-editor\/widgets\/"},{"@type":"ListItem","position":4,"name":"Basic functionality","item":"https:\/\/elementor.com\/help\/elementor-editor\/widgets\/basic-functionality\/"},{"@type":"ListItem","position":5,"name":"Code Highlight widget"}]},{"@type":"WebSite","@id":"https:\/\/elementor.com\/help\/#website","url":"https:\/\/elementor.com\/help\/","name":"Elementor","description":"","publisher":{"@id":"https:\/\/elementor.com\/help\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/elementor.com\/help\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/elementor.com\/help\/#organization","name":"Elementor","url":"https:\/\/elementor.com\/help\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/elementor.com\/help\/#\/schema\/logo\/image\/","url":"https:\/\/elementor.com\/help\/wp-content\/uploads\/2025\/06\/images.png","contentUrl":"https:\/\/elementor.com\/help\/wp-content\/uploads\/2025\/06\/images.png","width":225,"height":225,"caption":"Elementor"},"image":{"@id":"https:\/\/elementor.com\/help\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/elementor.com\/help\/#\/schema\/person\/ebf805be1a1abdd587d4b97e3328f430","name":"Alan Kaler","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/elementor.com\/help\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/7618989d1401c38afe50748601d8dad91fdb8930f53fe037881768b15ab4b108?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/7618989d1401c38afe50748601d8dad91fdb8930f53fe037881768b15ab4b108?s=96&d=mm&r=g","caption":"Alan Kaler"},"description":"Alan Kaler is an expert Elementorist at Elementor and a WordPress Magician who thinks that the three most beautiful words in our language are: I told you"}]}},"_links":{"self":[{"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/posts\/18917","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/comments?post=18917"}],"version-history":[{"count":2,"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/posts\/18917\/revisions"}],"predecessor-version":[{"id":36862,"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/posts\/18917\/revisions\/36862"}],"wp:attachment":[{"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/media?parent=18917"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/categories?post=18917"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/elementor.com\/help\/wp-json\/wp\/v2\/tags?post=18917"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}