{"id":5371,"date":"2020-09-10T05:36:23","date_gmt":"2020-09-10T05:36:23","guid":{"rendered":"http:\/\/www.webhosting.uk.com\/kb\/?p=5371"},"modified":"2026-03-24T12:54:00","modified_gmt":"2026-03-24T12:54:00","slug":"how-to-enable-ip-forwarding-on-linux-ipv4-ipv6","status":"publish","type":"post","link":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/","title":{"rendered":"How to Enable IP forwarding on Linux (IPv4 \/ IPv6)"},"content":{"rendered":"<p>IP forwarding is the feature that allows Linux OS to receive network packets arriving on one interface and then forward them to another network. Most Linux distributions disable IP forwarding because not everyone needs this feature. However, you have to enable IP forwarding if you want to set up a Linux router, gateway, VPN server, or connect multiple networks.<\/p>\r\n<h2>Enable IP Forwarding<\/h2>\r\n<p>There are two ways to enable IP forwarding on Linux: Temporary activation and Permanent Activation.<\/p>\r\n<p>First, we will check if the current IP forwarding is enabled or not.<\/p>\r\n<!-- \/wp:post-content -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>Here we have to query the\u00a0sysctl kernel\u00a0value\u00a0net.ipv4.ip_forward\u00a0to check if IP forwarding is enabled or not: Using\u00a0sysctl:<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:preformatted -->\r\n<pre class=\"wp-block-preformatted\">sysctl net.ipv4.ip_forward \r\nnet.ipv4.ip_forward = 0\r\n<\/pre>\r\n<!-- \/wp:preformatted -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>Or just check out the value in the\u00a0\/proc\u00a0system:<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:preformatted -->\r\n<pre class=\"wp-block-preformatted\">cat \/proc\/sys\/net\/ipv4\/ip_forward \r\n0<\/pre>\r\n<!-- \/wp:preformatted -->\r\n\r\n<!-- wp:image {\"id\":5372,\"width\":672,\"height\":87,\"sizeSlug\":\"large\"} -->\r\n<p><img decoding=\"async\" class=\"alignnone\" style=\"border: 1px solid #ccc; border-radius: 6px; padding: 4px;\" src=\"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/Ip-1.png\" alt=\"cat\" height=\"108\" \/><\/p>\r\n<!-- \/wp:image -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>As per the above examples, we can see this was\u00a0<em>disabled<\/em>\u00a0(as shown by the\u00a0value 0).<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:heading {\"level\":4} -->\r\n<h3>Temporary Activation<\/h3>\r\n<!-- \/wp:heading -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>The activation and deactivation of IP forwarding, in IPv4, as is IPv6, is handled in \/proc files. This is \u201c<em>\/proc\/sys\/net\/ipv4\/ip_forward<\/em>\u201d for IPv4 and \u201c<em>\/proc\/sys\/net\/ipv6\/conf\/all\/forwarding<\/em>\u201d\u00a0for IPv6.<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>If we do a \u201c<em>cat<\/em>\u201d on these files, we will see that they are by default to 0, to activate the IP forwarding temporarily, it is enough to set them to 1. One can then modify the file or use the \u201csysctl\u201d command:<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:preformatted -->\r\n<pre class=\"wp-block-preformatted\">sysctl -w net.ipv4.ip_forward=1<\/pre>\r\n<!-- \/wp:preformatted -->\r\n\r\n<!-- wp:image {\"id\":5373,\"width\":663,\"height\":111,\"sizeSlug\":\"large\"} -->\r\n<p><img decoding=\"async\" class=\"alignnone\" style=\"border: 1px solid #ccc; border-radius: 6px; padding: 4px;\" src=\"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/ip2.png\" alt=\"temporary activation\" height=\"141\" \/><\/p>\r\n<!-- \/wp:image -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>Or, following is one more command to enable temporarily:<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:preformatted -->\r\n<pre class=\"wp-block-preformatted\">echo 1 &gt; \/proc\/sys\/net\/ipv4\/ip_forward<\/pre>\r\n<!-- \/wp:preformatted -->\r\n\r\n<!-- wp:paragraph -->\r\n<div>Please note that this is a temporary activation. So the IP forwarding setting will return to its default value when the machine is restarted.<\/div>\r\n<div>\u00a0<\/div>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:paragraph \/-->\r\n\r\n<!-- wp:heading {\"level\":4} -->\r\n<h3>Permanent Activation<\/h3>\r\n<!-- \/wp:heading -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>To enable these changes permanently, you have to modify the configuration file of sysctl so that it loads our modifications each start. It is the file \u201c<em>\/etc\/sysctl.conf<\/em>\u201d to activate IPv4 IP forwarding. We will add or uncomment this line:<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:preformatted -->\r\n<pre class=\"wp-block-preformatted\">net.ipv4.ip_forward = 1<\/pre>\r\n<!-- \/wp:preformatted -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>For IPv6, we will do the same with this line:<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:preformatted -->\r\n<pre class=\"wp-block-preformatted\">net.ipv6.conf.all.forwarding=1<\/pre>\r\n<!-- \/wp:preformatted -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>The configuration can then be reloaded so that the changes take effect immediately:<\/p>\r\n<!-- \/wp:paragraph -->\r\n\r\n<!-- wp:preformatted -->\r\n<pre class=\"wp-block-preformatted\">sysctl -p \/etc\/sysctl.conf<\/pre>\r\n<!-- \/wp:preformatted -->\r\n\r\n<!-- wp:image {\"id\":5374,\"sizeSlug\":\"large\"} -->\r\n<p><img decoding=\"async\" class=\"alignnone\" style=\"border: 1px solid #ccc; border-radius: 6px; padding: 4px;\" src=\"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/ip3.png\" alt=\"Permanent activation\" height=\"366\" \/><\/p>\r\n<!-- \/wp:image -->\r\n\r\n<!-- wp:paragraph -->\r\n<p>That\u2019s it! You have successfully performed the activation.<\/p>\r\n<!-- \/wp:paragraph -->\r\n<p>You have now successfully set up IP forwarding on your Linux system by following these steps. It can now forward network packets between networks.<\/p>\r\n<!-- \/wp:paragraph -->\r\n<div style=\"background: #E6F0FF; padding: 15px; border-left: 4px solid #0047BA; margin: 20px 0;\"><strong>Configuring advanced networking in Linux?<\/strong><br \/>For better control over routing and network settings, consider using a <a href=\"https:\/\/www.webhosting.uk.com\/linux-vps\">Linux VPS with full system access<\/a>.<\/div>","protected":false},"excerpt":{"rendered":"<p>IP forwarding is the feature that allows Linux OS to receive network packets arriving on one interface and then forward them to another network. Most Linux distributions disable IP forwarding&hellip;<\/p>\n<p><a href=\"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/\" class=\"more-link\">Read More<\/a><\/p>\n<div class='heateorSssClear'><\/div><div  class='heateor_sss_sharing_container heateor_sss_horizontal_sharing' data-heateor-sss-href='https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/'><div class='heateor_sss_sharing_title' style=\"font-weight:bold\" >Spread the love<\/div><div class=\"heateor_sss_sharing_ul\"><a aria-label=\"Facebook\" class=\"heateor_sss_facebook\" href=\"https:\/\/www.facebook.com\/sharer\/sharer.php?u=https%3A%2F%2Fwww.webhosting.uk.com%2Fkb%2Fhow-to-enable-ip-forwarding-on-linux-ipv4-ipv6%2F\" title=\"Facebook\" rel=\"nofollow noopener\" target=\"_blank\" style=\"font-size:32px!important;box-shadow:none;display:inline-block;vertical-align:middle\"><span class=\"heateor_sss_svg\" style=\"background-color:#0765FE;width:40px;height:40px;display:inline-block;opacity:1;float:left;font-size:32px;box-shadow:none;display:inline-block;font-size:16px;padding:0 4px;vertical-align:middle;background-repeat:repeat;overflow:hidden;padding:0;cursor:pointer;box-sizing:content-box\"><svg style=\"display:block;\" focusable=\"false\" aria-hidden=\"true\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"100%\" height=\"100%\" viewBox=\"0 0 32 32\"><path fill=\"#fff\" d=\"M28 16c0-6.627-5.373-12-12-12S4 9.373 4 16c0 5.628 3.875 10.35 9.101 11.647v-7.98h-2.474V16H13.1v-1.58c0-4.085 1.849-5.978 5.859-5.978.76 0 2.072.15 2.608.298v3.325c-.283-.03-.775-.045-1.386-.045-1.967 0-2.728.745-2.728 2.683V16h3.92l-.673 3.667h-3.247v8.245C23.395 27.195 28 22.135 28 16Z\"><\/path><\/svg><\/span><\/a><a aria-label=\"X\" class=\"heateor_sss_button_x\" href=\"https:\/\/twitter.com\/intent\/tweet?text=How%20to%20enable%20IP%20forwarding%20on%20Linux%20%28IPv4%20%2F%20IPv6%29&url=https%3A%2F%2Fwww.webhosting.uk.com%2Fkb%2Fhow-to-enable-ip-forwarding-on-linux-ipv4-ipv6%2F\" title=\"X\" rel=\"nofollow noopener\" target=\"_blank\" style=\"font-size:32px!important;box-shadow:none;display:inline-block;vertical-align:middle\"><span class=\"heateor_sss_svg heateor_sss_s__default heateor_sss_s_x\" style=\"background-color:#2a2a2a;width:40px;height:40px;display:inline-block;opacity:1;float:left;font-size:32px;box-shadow:none;display:inline-block;font-size:16px;padding:0 4px;vertical-align:middle;background-repeat:repeat;overflow:hidden;padding:0;cursor:pointer;box-sizing:content-box\"><svg width=\"100%\" height=\"100%\" style=\"display:block;\" focusable=\"false\" aria-hidden=\"true\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 32 32\"><path fill=\"#fff\" d=\"M21.751 7h3.067l-6.7 7.658L26 25.078h-6.172l-4.833-6.32-5.531 6.32h-3.07l7.167-8.19L6 7h6.328l4.37 5.777L21.75 7Zm-1.076 16.242h1.7L11.404 8.74H9.58l11.094 14.503Z\"><\/path><\/svg><\/span><\/a><a aria-label=\"Linkedin\" class=\"heateor_sss_button_linkedin\" href=\"https:\/\/www.linkedin.com\/sharing\/share-offsite\/?url=https%3A%2F%2Fwww.webhosting.uk.com%2Fkb%2Fhow-to-enable-ip-forwarding-on-linux-ipv4-ipv6%2F\" title=\"Linkedin\" rel=\"nofollow noopener\" target=\"_blank\" style=\"font-size:32px!important;box-shadow:none;display:inline-block;vertical-align:middle\"><span class=\"heateor_sss_svg heateor_sss_s__default heateor_sss_s_linkedin\" style=\"background-color:#0077b5;width:40px;height:40px;display:inline-block;opacity:1;float:left;font-size:32px;box-shadow:none;display:inline-block;font-size:16px;padding:0 4px;vertical-align:middle;background-repeat:repeat;overflow:hidden;padding:0;cursor:pointer;box-sizing:content-box\"><svg style=\"display:block;\" focusable=\"false\" aria-hidden=\"true\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"100%\" height=\"100%\" viewBox=\"0 0 32 32\"><path d=\"M6.227 12.61h4.19v13.48h-4.19V12.61zm2.095-6.7a2.43 2.43 0 0 1 0 4.86c-1.344 0-2.428-1.09-2.428-2.43s1.084-2.43 2.428-2.43m4.72 6.7h4.02v1.84h.058c.56-1.058 1.927-2.176 3.965-2.176 4.238 0 5.02 2.792 5.02 6.42v7.395h-4.183v-6.56c0-1.564-.03-3.574-2.178-3.574-2.18 0-2.514 1.7-2.514 3.46v6.668h-4.187V12.61z\" fill=\"#fff\"><\/path><\/svg><\/span><\/a><\/div><div class=\"heateorSssClear\"><\/div><\/div><div class='heateorSssClear'><\/div>","protected":false},"author":28,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1853],"tags":[1836],"class_list":["post-5371","post","type-post","status-publish","format-standard","hentry","category-howto-guide","tag-ip-address"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.9 (Yoast SEO v27.9) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Enable IPv6 Forwarding in Linux (IPv4 &amp; IPv6 Guide)<\/title>\n<meta name=\"description\" content=\"Enable IPv6 forwarding in Linux with simple commands. Step-by-step guide for configuring IPv4 and IPv6 forwarding.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/\" \/>\n<meta property=\"og:locale\" content=\"en_GB\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to enable IP forwarding on Linux (IPv4 \/ IPv6)\" \/>\n<meta property=\"og:description\" content=\"Enable IPv6 forwarding in Linux with simple commands. Step-by-step guide for configuring IPv4 and IPv6 forwarding.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/\" \/>\n<meta property=\"og:site_name\" content=\"Webhosting UK Knowledge Base\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/webhostingukcom\" \/>\n<meta property=\"article:published_time\" content=\"2020-09-10T05:36:23+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-03-24T12:54:00+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/Ip-1.png\" \/>\n<meta name=\"author\" content=\"Victor G\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:title\" content=\"How to enable IP forwarding on Linux (IPv4 \/ IPv6)\" \/>\n<meta name=\"twitter:creator\" content=\"@WebhostingUKcom\" \/>\n<meta name=\"twitter:site\" content=\"@WebhostingUKcom\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/\"},\"author\":{\"name\":\"Victor G\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#\\\/schema\\\/person\\\/ea067684eae84c2b8b49a81c69407297\"},\"headline\":\"How to Enable IP forwarding on Linux (IPv4 \\\/ IPv6)\",\"datePublished\":\"2020-09-10T05:36:23+00:00\",\"dateModified\":\"2026-03-24T12:54:00+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/\"},\"wordCount\":383,\"publisher\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/wp-content\\\/uploads\\\/2020\\\/09\\\/Ip-1.png\",\"keywords\":[\"IP address\"],\"articleSection\":[\"How-to Guide\"],\"inLanguage\":\"en-GB\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/\",\"url\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/\",\"name\":\"Enable IPv6 Forwarding in Linux (IPv4 & IPv6 Guide)\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/wp-content\\\/uploads\\\/2020\\\/09\\\/Ip-1.png\",\"datePublished\":\"2020-09-10T05:36:23+00:00\",\"dateModified\":\"2026-03-24T12:54:00+00:00\",\"description\":\"Enable IPv6 forwarding in Linux with simple commands. Step-by-step guide for configuring IPv4 and IPv6 forwarding.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/#breadcrumb\"},\"inLanguage\":\"en-GB\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/wp-content\\\/uploads\\\/2020\\\/09\\\/Ip-1.png\",\"contentUrl\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/wp-content\\\/uploads\\\/2020\\\/09\\\/Ip-1.png\",\"width\":830,\"height\":108,\"caption\":\"[root@centos ~1#\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Enable IP forwarding on Linux (IPv4 \\\/ IPv6)\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#website\",\"url\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/\",\"name\":\"Webhosting UK Knowledge Base\",\"description\":\"Expert Insights on Hosting, Development, Security, Marketing, and SEO\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#organization\"},\"alternateName\":\"WHUK\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-GB\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#organization\",\"name\":\"Webhosting UK\",\"alternateName\":\"WHUK\",\"url\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/wp-content\\\/uploads\\\/2023\\\/08\\\/WHUK-logo-1.png\",\"contentUrl\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/wp-content\\\/uploads\\\/2023\\\/08\\\/WHUK-logo-1.png\",\"width\":1200,\"height\":628,\"caption\":\"Webhosting UK\"},\"image\":{\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/webhostingukcom\",\"https:\\\/\\\/x.com\\\/WebhostingUKcom\",\"https:\\\/\\\/www.youtube.com\\\/c\\\/webhostinguk\",\"https:\\\/\\\/www.linkedin.com\\\/company\\\/webhosting-uk-com-ltd\\\/\",\"https:\\\/\\\/www.instagram.com\\\/webhosting_uk\\\/\",\"https:\\\/\\\/www.tiktok.com\\\/@webhostinguk\"],\"description\":\"Fast, reliable, and cost-effective website hosting services with Webhosting UK. Committed to providing you secure support around the clock.\",\"email\":\"sales@webhosting.uk.com\",\"telephone\":\"0800 862 0890\",\"legalName\":\"Webhosting UK\",\"foundingDate\":\"2001-02-07\",\"numberOfEmployees\":{\"@type\":\"QuantitativeValue\",\"minValue\":\"51\",\"maxValue\":\"200\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.webhosting.uk.com\\\/kb\\\/#\\\/schema\\\/person\\\/ea067684eae84c2b8b49a81c69407297\",\"name\":\"Victor G\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/9bf0713adcbaded4878508c93d93927ecbfa4f74548fd9bcee41478d8768bd66?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/9bf0713adcbaded4878508c93d93927ecbfa4f74548fd9bcee41478d8768bd66?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/9bf0713adcbaded4878508c93d93927ecbfa4f74548fd9bcee41478d8768bd66?s=96&d=mm&r=g\",\"caption\":\"Victor G\"}}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Enable IPv6 Forwarding in Linux (IPv4 & IPv6 Guide)","description":"Enable IPv6 forwarding in Linux with simple commands. Step-by-step guide for configuring IPv4 and IPv6 forwarding.","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:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/","og_locale":"en_GB","og_type":"article","og_title":"How to enable IP forwarding on Linux (IPv4 \/ IPv6)","og_description":"Enable IPv6 forwarding in Linux with simple commands. Step-by-step guide for configuring IPv4 and IPv6 forwarding.","og_url":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/","og_site_name":"Webhosting UK Knowledge Base","article_publisher":"https:\/\/www.facebook.com\/webhostingukcom","article_published_time":"2020-09-10T05:36:23+00:00","article_modified_time":"2026-03-24T12:54:00+00:00","og_image":[{"url":"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/Ip-1.png","type":"","width":"","height":""}],"author":"Victor G","twitter_card":"summary_large_image","twitter_title":"How to enable IP forwarding on Linux (IPv4 \/ IPv6)","twitter_creator":"@WebhostingUKcom","twitter_site":"@WebhostingUKcom","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/#article","isPartOf":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/"},"author":{"name":"Victor G","@id":"https:\/\/www.webhosting.uk.com\/kb\/#\/schema\/person\/ea067684eae84c2b8b49a81c69407297"},"headline":"How to Enable IP forwarding on Linux (IPv4 \/ IPv6)","datePublished":"2020-09-10T05:36:23+00:00","dateModified":"2026-03-24T12:54:00+00:00","mainEntityOfPage":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/"},"wordCount":383,"publisher":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/#organization"},"image":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/#primaryimage"},"thumbnailUrl":"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/Ip-1.png","keywords":["IP address"],"articleSection":["How-to Guide"],"inLanguage":"en-GB"},{"@type":"WebPage","@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/","url":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/","name":"Enable IPv6 Forwarding in Linux (IPv4 & IPv6 Guide)","isPartOf":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/#primaryimage"},"image":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/#primaryimage"},"thumbnailUrl":"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/Ip-1.png","datePublished":"2020-09-10T05:36:23+00:00","dateModified":"2026-03-24T12:54:00+00:00","description":"Enable IPv6 forwarding in Linux with simple commands. Step-by-step guide for configuring IPv4 and IPv6 forwarding.","breadcrumb":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/#breadcrumb"},"inLanguage":"en-GB","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/"]}]},{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/#primaryimage","url":"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/Ip-1.png","contentUrl":"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2020\/09\/Ip-1.png","width":830,"height":108,"caption":"[root@centos ~1#"},{"@type":"BreadcrumbList","@id":"https:\/\/www.webhosting.uk.com\/kb\/how-to-enable-ip-forwarding-on-linux-ipv4-ipv6\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.webhosting.uk.com\/kb\/"},{"@type":"ListItem","position":2,"name":"How to Enable IP forwarding on Linux (IPv4 \/ IPv6)"}]},{"@type":"WebSite","@id":"https:\/\/www.webhosting.uk.com\/kb\/#website","url":"https:\/\/www.webhosting.uk.com\/kb\/","name":"Webhosting UK Knowledge Base","description":"Expert Insights on Hosting, Development, Security, Marketing, and SEO","publisher":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/#organization"},"alternateName":"WHUK","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.webhosting.uk.com\/kb\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-GB"},{"@type":"Organization","@id":"https:\/\/www.webhosting.uk.com\/kb\/#organization","name":"Webhosting UK","alternateName":"WHUK","url":"https:\/\/www.webhosting.uk.com\/kb\/","logo":{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/www.webhosting.uk.com\/kb\/#\/schema\/logo\/image\/","url":"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2023\/08\/WHUK-logo-1.png","contentUrl":"https:\/\/www.webhosting.uk.com\/kb\/wp-content\/uploads\/2023\/08\/WHUK-logo-1.png","width":1200,"height":628,"caption":"Webhosting UK"},"image":{"@id":"https:\/\/www.webhosting.uk.com\/kb\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/webhostingukcom","https:\/\/x.com\/WebhostingUKcom","https:\/\/www.youtube.com\/c\/webhostinguk","https:\/\/www.linkedin.com\/company\/webhosting-uk-com-ltd\/","https:\/\/www.instagram.com\/webhosting_uk\/","https:\/\/www.tiktok.com\/@webhostinguk"],"description":"Fast, reliable, and cost-effective website hosting services with Webhosting UK. Committed to providing you secure support around the clock.","email":"sales@webhosting.uk.com","telephone":"0800 862 0890","legalName":"Webhosting UK","foundingDate":"2001-02-07","numberOfEmployees":{"@type":"QuantitativeValue","minValue":"51","maxValue":"200"}},{"@type":"Person","@id":"https:\/\/www.webhosting.uk.com\/kb\/#\/schema\/person\/ea067684eae84c2b8b49a81c69407297","name":"Victor G","image":{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/secure.gravatar.com\/avatar\/9bf0713adcbaded4878508c93d93927ecbfa4f74548fd9bcee41478d8768bd66?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/9bf0713adcbaded4878508c93d93927ecbfa4f74548fd9bcee41478d8768bd66?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/9bf0713adcbaded4878508c93d93927ecbfa4f74548fd9bcee41478d8768bd66?s=96&d=mm&r=g","caption":"Victor G"}}]}},"_links":{"self":[{"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/posts\/5371","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/users\/28"}],"replies":[{"embeddable":true,"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/comments?post=5371"}],"version-history":[{"count":13,"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/posts\/5371\/revisions"}],"predecessor-version":[{"id":22637,"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/posts\/5371\/revisions\/22637"}],"wp:attachment":[{"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/media?parent=5371"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/categories?post=5371"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.webhosting.uk.com\/kb\/wp-json\/wp\/v2\/tags?post=5371"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}