{"id":642,"date":"2021-07-26T12:05:00","date_gmt":"2021-07-26T12:05:00","guid":{"rendered":"https:\/\/www.34sp.com/kb\/?p=642"},"modified":"2026-01-28T11:43:38","modified_gmt":"2026-01-28T11:43:38","slug":"how-to-edit-your-host-file-on-macos","status":"publish","type":"post","link":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos","title":{"rendered":"How to edit your host file on macOS"},"content":{"rendered":"\n<div class=\"wp-block-columns has-background is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\" style=\"background-color:#f6faff\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Applies to:<\/strong><br>Domains<br>Professional Hosting<br>Universal Hosting<br>Reseller Hosting<br>VPS Hosting<br>WordPress Hosting<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Difficulty:<\/strong><br>Easy<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<p class=\"has-black-color has-text-color wp-block-paragraph\"><strong>Time Needed:<\/strong><br>5 minutes<\/p>\n<\/div>\n<\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Introduction<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">This is a quick step-by-step guide to editing your host file on macOS. Editing your host file is a great way of viewing a specific web server prior to updating your DNS, or whilst it is propagating.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you are a Windows user, please see our Knowledge Base article&nbsp;&#8216;How to edit your host file on Windows&#8217;.<\/p>\n\n\n\n<hr class=\"wp-block-separator is-style-wide\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">How to edit your host file on macOS<\/h2>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h5 class=\"wp-block-heading\">STEP 1<br>Choose &#8216;Go&#8217;<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">When running macOS, click on the Finder icon, then choose&nbsp;<strong>&#8216;Go&#8217;<\/strong>&nbsp;from the menu bar.<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"270\" src=\"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1.jpg\" alt=\"\" class=\"wp-image-643\" srcset=\"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1.jpg 450w, https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1-300x180.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/figure>\n<\/div>\n<\/div>\n\n\n\n<hr class=\"wp-block-separator is-style-wide\"\/>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h5 class=\"wp-block-heading\">STEP 2<br>Open &#8216;Utilities&#8217;<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">From the drop down menu, select&nbsp;<strong>&#8216;Utilities&#8217;<\/strong>.<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"270\" src=\"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-02.1.jpg\" alt=\"\" class=\"wp-image-644\" srcset=\"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-02.1.jpg 450w, https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-02.1-300x180.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/figure>\n<\/div>\n<\/div>\n\n\n\n<hr class=\"wp-block-separator is-style-wide\"\/>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h5 class=\"wp-block-heading\">STEP 3<br>Select &#8216;Terminal&#8217;<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This will then open the&nbsp;<strong>&#8216;Utilities&#8217;<\/strong>&nbsp;settings. Locate the icon labelled&nbsp;<strong>&#8216;Terminal&#8217;<\/strong>, and double click on it.<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"270\" src=\"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-03.1.jpg\" alt=\"\" class=\"wp-image-646\" srcset=\"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-03.1.jpg 450w, https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-03.1-300x180.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/figure>\n<\/div>\n<\/div>\n\n\n\n<hr class=\"wp-block-separator is-style-wide\"\/>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h5 class=\"wp-block-heading\">STEP 4<br>Run the command<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This will bring up your command prompt. Simply enter the following, and press the&nbsp;<strong>&#8216;Return&#8217;<\/strong>&nbsp;key.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><code>sudo nano \/etc\/hosts<\/code><\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"270\" src=\"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-01.1.jpg\" alt=\"\" class=\"wp-image-647\" srcset=\"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-01.1.jpg 450w, https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-01.1-300x180.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/figure>\n<\/div>\n<\/div>\n\n\n\n<hr class=\"wp-block-separator is-style-wide\"\/>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h5 class=\"wp-block-heading\">STEP 5<br>Edit the host file<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">This will open your host file. To add a new server or domain, move the cursor to the bottom of the file using the arrows keys. Once you have moved the cursor to the end of the file, enter the&nbsp;<strong>IP address<\/strong>&nbsp;of your server, press the&nbsp;<strong>&#8216;Tab&#8217;<\/strong>&nbsp;key, then enter your&nbsp;<strong>domain name<\/strong>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The following is an example, you will need to update these to your relevant IP address and URL.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><code>127.0.0.1 yourdomain.com<\/code><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">When you have entered the relevant IP address and url, hold down\u00a0<kbd>CTRL<\/kbd>\u00a0and press the\u00a0o\u00a0key, then press the\u00a0<kbd>Return<\/kbd>\u00a0key to save your changes. Then simply hold down\u00a0<kbd>CTRL<\/kbd>\u00a0key and press the\u00a0<kbd>X<\/kbd>\u00a0key to exit and return back to your command prompt.<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"270\" src=\"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-02.1.jpg\" alt=\"\" class=\"wp-image-648\" srcset=\"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-02.1.jpg 450w, https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-02.1-300x180.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/figure>\n<\/div>\n<\/div>\n\n\n\n<hr class=\"wp-block-separator is-style-wide\"\/>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<h5 class=\"wp-block-heading\">STEP 6<br>Flush your DNS<\/h5>\n\n\n\n<p class=\"wp-block-paragraph\">For the final step, simply enter the following command to flush your Mac&#8217;s DNS cache.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><code>sudo killall -HUP mDNSResponder<\/code><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">After running the above command, return back to your web browser and enter the domain you added to your host file. If the site changes from the one of the public can see, to the one on your new server, then you have edited the host file successfully.<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"270\" src=\"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-03.1.jpg\" alt=\"\" class=\"wp-image-649\" srcset=\"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-03.1.jpg 450w, https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-hostfile-osx-03.1-300x180.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/figure>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Applies to:DomainsProfessional HostingUniversal HostingReseller HostingVPS HostingWordPress Hosting Difficulty:Easy Time Needed:5 minutes Introduction This is a quick step-by-step guide to editing your host file on macOS. Editing your host file is&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,95,3,30,2],"tags":[],"class_list":["post-642","post","type-post","status-publish","format-standard","hentry","category-domain-names","category-general","category-professional-hosting","category-universal-hosting","category-wordpress-hosting"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How to edit your host file on macOS | Knowledge Base<\/title>\n<meta name=\"description\" content=\"This is a quick step-by-step guide to editing your host file on macOS.\" \/>\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.34sp.com/kb\/how-to-edit-your-host-file-on-macos\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to edit your host file on macOS | Knowledge Base\" \/>\n<meta property=\"og:description\" content=\"This is a quick step-by-step guide to editing your host file on macOS.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/34SPWebsiteHosts\/\" \/>\n<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/34SPWebsiteHosts\" \/>\n<meta property=\"article:published_time\" content=\"2021-07-26T12:05:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-01-28T11:43:38+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"450\" \/>\n\t<meta property=\"og:image:height\" content=\"270\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Kayleigh\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@34sp\" \/>\n<meta name=\"twitter:site\" content=\"@34sp\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Kayleigh\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos\"},\"author\":{\"name\":\"Kayleigh\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#\\\/schema\\\/person\\\/daa527106d35aab27ee3d39e12112172\"},\"headline\":\"How to edit your host file on macOS\",\"datePublished\":\"2021-07-26T12:05:00+00:00\",\"dateModified\":\"2026-01-28T11:43:38+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos\"},\"wordCount\":361,\"publisher\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/kb.34sp.com\\\/wp-content\\\/uploads\\\/2021\\\/07\\\/generic-traceroute-osx-01.1.jpg\",\"articleSection\":[\"Domain Names\",\"General\",\"Professional Hosting\",\"Universal Hosting\",\"WordPress Hosting\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos\",\"url\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos\",\"name\":\"How to edit your host file on macOS | Knowledge Base\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/kb.34sp.com\\\/wp-content\\\/uploads\\\/2021\\\/07\\\/generic-traceroute-osx-01.1.jpg\",\"datePublished\":\"2021-07-26T12:05:00+00:00\",\"dateModified\":\"2026-01-28T11:43:38+00:00\",\"description\":\"This is a quick step-by-step guide to editing your host file on macOS.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos#primaryimage\",\"url\":\"https:\\\/\\\/www.34sp.com\\\/kb\\\/wp-content\\\/uploads\\\/2021\\\/07\\\/generic-traceroute-osx-01.1.jpg\",\"contentUrl\":\"https:\\\/\\\/www.34sp.com\\\/kb\\\/wp-content\\\/uploads\\\/2021\\\/07\\\/generic-traceroute-osx-01.1.jpg\",\"width\":450,\"height\":270},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/how-to-edit-your-host-file-on-macos#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/kb.34sp.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to edit your host file on macOS\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#website\",\"url\":\"https:\\\/\\\/kb.34sp.com\\\/\",\"name\":\"\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/kb.34sp.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#organization\",\"name\":\"34SP.com Limited\",\"url\":\"https:\\\/\\\/kb.34sp.com\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/kb.34sp.com\\\/wp-content\\\/uploads\\\/2022\\\/06\\\/34sp-logo-horizontal-blue.png\",\"contentUrl\":\"https:\\\/\\\/kb.34sp.com\\\/wp-content\\\/uploads\\\/2022\\\/06\\\/34sp-logo-horizontal-blue.png\",\"width\":3000,\"height\":1286,\"caption\":\"34SP.com Limited\"},\"image\":{\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/34SPWebsiteHosts\\\/\",\"https:\\\/\\\/x.com\\\/34sp\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/kb.34sp.com\\\/#\\\/schema\\\/person\\\/daa527106d35aab27ee3d39e12112172\",\"name\":\"Kayleigh\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/cee8c3564bca088c8f3300447726634e7e34d11b2002b3de29996ba4da754343?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/cee8c3564bca088c8f3300447726634e7e34d11b2002b3de29996ba4da754343?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/cee8c3564bca088c8f3300447726634e7e34d11b2002b3de29996ba4da754343?s=96&d=mm&r=g\",\"caption\":\"Kayleigh\"},\"description\":\"As part of the Customer Experience team, Kayleigh ensures that all of our customers get the highest quality of service. Kayleigh started with 34SP in 2014 and is one of our WordPress experts. Kayleigh provides all of our support staff with ongoing training and works to improve their knowledge across a broad range of subjects.\",\"sameAs\":[\"https:\\\/\\\/www.34SP.com\",\"https:\\\/\\\/www.facebook.com\\\/34SPWebsiteHosts\",\"https:\\\/\\\/www.instagram.com\\\/34sp\\\/\",\"https:\\\/\\\/www.linkedin.com\\\/company\\\/34sp.com\",\"https:\\\/\\\/www.pinterest.co.uk\\\/34SP\",\"https:\\\/\\\/x.com\\\/34sp\",\"https:\\\/\\\/www.youtube.com\\\/c\\\/34SPcomLtd\"],\"url\":\"https:\\\/\\\/kb.34sp.com\\\/author\\\/wp7ctmdod3qm\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to edit your host file on macOS | Knowledge Base","description":"This is a quick step-by-step guide to editing your host file on macOS.","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.34sp.com/kb\/how-to-edit-your-host-file-on-macos","og_locale":"en_US","og_type":"article","og_title":"How to edit your host file on macOS | Knowledge Base","og_description":"This is a quick step-by-step guide to editing your host file on macOS.","og_url":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos","article_publisher":"https:\/\/www.facebook.com\/34SPWebsiteHosts\/","article_author":"https:\/\/www.facebook.com\/34SPWebsiteHosts","article_published_time":"2021-07-26T12:05:00+00:00","article_modified_time":"2026-01-28T11:43:38+00:00","og_image":[{"width":450,"height":270,"url":"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1.jpg","type":"image\/jpeg"}],"author":"Kayleigh","twitter_card":"summary_large_image","twitter_creator":"@34sp","twitter_site":"@34sp","twitter_misc":{"Written by":"Kayleigh","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos#article","isPartOf":{"@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos"},"author":{"name":"Kayleigh","@id":"https:\/\/www.34sp.com/kb\/#\/schema\/person\/daa527106d35aab27ee3d39e12112172"},"headline":"How to edit your host file on macOS","datePublished":"2021-07-26T12:05:00+00:00","dateModified":"2026-01-28T11:43:38+00:00","mainEntityOfPage":{"@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos"},"wordCount":361,"publisher":{"@id":"https:\/\/www.34sp.com/kb\/#organization"},"image":{"@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos#primaryimage"},"thumbnailUrl":"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1.jpg","articleSection":["Domain Names","General","Professional Hosting","Universal Hosting","WordPress Hosting"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos","url":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos","name":"How to edit your host file on macOS | Knowledge Base","isPartOf":{"@id":"https:\/\/www.34sp.com/kb\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos#primaryimage"},"image":{"@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos#primaryimage"},"thumbnailUrl":"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1.jpg","datePublished":"2021-07-26T12:05:00+00:00","dateModified":"2026-01-28T11:43:38+00:00","description":"This is a quick step-by-step guide to editing your host file on macOS.","breadcrumb":{"@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos#primaryimage","url":"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1.jpg","contentUrl":"https:\/\/www.34sp.com\/kb\/wp-content\/uploads\/2021\/07\/generic-traceroute-osx-01.1.jpg","width":450,"height":270},{"@type":"BreadcrumbList","@id":"https:\/\/www.34sp.com/kb\/how-to-edit-your-host-file-on-macos#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.34sp.com/kb\/"},{"@type":"ListItem","position":2,"name":"How to edit your host file on macOS"}]},{"@type":"WebSite","@id":"https:\/\/www.34sp.com/kb\/#website","url":"https:\/\/www.34sp.com/kb\/","name":"","description":"","publisher":{"@id":"https:\/\/www.34sp.com/kb\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.34sp.com/kb\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.34sp.com/kb\/#organization","name":"34SP.com Limited","url":"https:\/\/www.34sp.com/kb\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.34sp.com/kb\/#\/schema\/logo\/image\/","url":"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2022\/06\/34sp-logo-horizontal-blue.png","contentUrl":"https:\/\/www.34sp.com/kb\/wp-content\/uploads\/2022\/06\/34sp-logo-horizontal-blue.png","width":3000,"height":1286,"caption":"34SP.com Limited"},"image":{"@id":"https:\/\/www.34sp.com/kb\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/34SPWebsiteHosts\/","https:\/\/x.com\/34sp"]},{"@type":"Person","@id":"https:\/\/www.34sp.com/kb\/#\/schema\/person\/daa527106d35aab27ee3d39e12112172","name":"Kayleigh","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/cee8c3564bca088c8f3300447726634e7e34d11b2002b3de29996ba4da754343?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/cee8c3564bca088c8f3300447726634e7e34d11b2002b3de29996ba4da754343?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/cee8c3564bca088c8f3300447726634e7e34d11b2002b3de29996ba4da754343?s=96&d=mm&r=g","caption":"Kayleigh"},"description":"As part of the Customer Experience team, Kayleigh ensures that all of our customers get the highest quality of service. Kayleigh started with 34SP in 2014 and is one of our WordPress experts. Kayleigh provides all of our support staff with ongoing training and works to improve their knowledge across a broad range of subjects.","sameAs":["https:\/\/www.34SP.com","https:\/\/www.facebook.com\/34SPWebsiteHosts","https:\/\/www.instagram.com\/34sp\/","https:\/\/www.linkedin.com\/company\/34sp.com","https:\/\/www.pinterest.co.uk\/34SP","https:\/\/x.com\/34sp","https:\/\/www.youtube.com\/c\/34SPcomLtd"],"url":"https:\/\/www.34sp.com/kb\/author\/wp7ctmdod3qm"}]}},"_links":{"self":[{"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/posts\/642","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/comments?post=642"}],"version-history":[{"count":2,"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/posts\/642\/revisions"}],"predecessor-version":[{"id":1733,"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/posts\/642\/revisions\/1733"}],"wp:attachment":[{"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/media?parent=642"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/categories?post=642"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.34sp.com/kb\/wp-json\/wp\/v2\/tags?post=642"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}