{"id":278,"date":"2013-06-17T22:58:00","date_gmt":"2013-06-17T22:58:00","guid":{"rendered":"http:\/\/55@jodohost.com\/\/blog\/"},"modified":"2013-06-17T22:58:00","modified_gmt":"2013-06-17T22:58:00","slug":"how-to-redirect-http-to-https-in-iis7-5","status":"publish","type":"post","link":"http:\/\/www.jodohost.com\/blog\/index.php\/2013\/06\/17\/how-to-redirect-http-to-https-in-iis7-5\/","title":{"rendered":"How to redirect http to https in IIS7.5"},"content":{"rendered":"<p>If you ever want to force your http traffic to https on IIS7 you can do the steps below. The steps here have been obtained after going through various forums and links which we tested and tried out. This worked for us so we&#8217;re putting it up here for everyone.<\/p>\n<p>How to redirect HTTP traffic to HTTPS on IIS7.<\/p>\n<p><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\">1. In IIS, click on the site name, and go to the<span class=\"Apple-converted-space\">\u00a0<\/span><\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\">SSL Settings<span class=\"Apple-converted-space\">\u00a0<\/span><\/strong><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\">section<\/span>.<br style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><br \/><img decoding=\"async\" src=\"http:\/\/www.sslshopper.com\/assets\/images\/iis7-redirect\/iis7-redirect-http-to-https1.jpg\" \/><\/p>\n<p>2. Check Require SSL and Require 128-bit SSL and click Apply.<\/p>\n<p><strong style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\"><span style=\"color: #000000;\"><\/span><br \/><img decoding=\"async\" src=\"http:\/\/www.sslshopper.com\/assets\/images\/iis7-redirect\/iis7-redirect-http-to-https2.jpg\" \/><\/strong><\/p>\n<p><span style=\"color: #000000;\"><\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><br \/><\/strong><\/p>\n<p><span style=\"color: #000000;\"><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><br style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><\/strong><\/span><span style=\"color: #ff0000;\"><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\"><\/span><\/strong><\/span><\/p>\n<p><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><img decoding=\"async\" src=\"http:\/\/www.sslshopper.com\/assets\/images\/iis7-redirect\/iis7-redirect-http-to-https3-error.jpg\" \/><\/strong><\/p>\n<p><span style=\"color: #000000;\"><\/span><span style=\"color: #000000;\">4.<\/span><span style=\"color: #000000;\"> Create a new text file and paste the following into it:<\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><\/strong><\/p>\n<p><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><html><\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><head><title>Redirecting&#8230;<\/title><\/head><\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><script language=\"JavaScript\"><\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\">function redirectHttpToHttps()<\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\">{<\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\">\u00a0\u00a0\u00a0 var httpURL= window.location.hostname + window.location.pathname + window.location.search;<\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\">\u00a0\u00a0\u00a0 var httpsURL= \"https:\/\/\" + httpURL;<\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\">\u00a0\u00a0\u00a0 window.location = httpsURL;<\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\">}<\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\">redirectHttpToHttps();<\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><\/script><\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><body><\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><\/body><\/span><br style=\"color: #000000; font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\" \/><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><\/html><\/span><\/span><\/strong><\/p>\n<p><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><br \/><\/span><\/span><\/strong><\/p>\n<p><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><span style=\"font-family: monospace; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; background-color: #f0f0f0; display: inline ! important; float: none;\"><\/span><\/span><\/strong><span style=\"color: #000000;\">5. Save the file as<span class=\"Apple-converted-space\">\u00a0<\/span><strong>redirectToHttps.htm<\/strong><span class=\"Apple-converted-space\">\u00a0<\/span>in your C:\\Inetpub directory.<\/span><\/p>\n<p><span style=\"color: #000000;\"><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\">6.Back in IIS, click on the site name and double-click the<span class=\"Apple-converted-space\">\u00a0<\/span><\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\">Error Pages<\/strong><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\"><span class=\"Apple-converted-space\">\u00a0<\/span>option.<\/span><\/span><\/p>\n<p><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><img decoding=\"async\" src=\"http:\/\/www.sslshopper.com\/assets\/images\/iis7-redirect\/iis7-redirect-http-to-https3.5.jpg\" \/><\/span><\/p>\n<p><span style=\"color: #000000; font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\">7. <span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\">Click<span class=\"Apple-converted-space\">\u00a0<\/span><\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\">Add\u2026<\/strong><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\"><span class=\"Apple-converted-space\">\u00a0<\/span>and enter<span class=\"Apple-converted-space\">\u00a0<\/span><\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\">403.4<\/strong><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\"><span class=\"Apple-converted-space\">\u00a0<\/span>as the Status code. Browse for the redirectToHttps.htm file you just created and click<span class=\"Apple-converted-space\">\u00a0<\/span><\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\">OK.<\/strong><\/span><\/p>\n<p><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><img decoding=\"async\" src=\"http:\/\/www.sslshopper.com\/assets\/images\/iis7-redirect\/iis7-redirect-http-to-https4-custom-error.jpg\" \/><\/span><\/p>\n<p><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><span style=\"color: #000000;\">8. <span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\">Select the error code and press<span class=\"Apple-converted-space\">\u00a0<\/span><\/span><\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\"><span style=\"color: #000000;\">Edit Feature Settings\u2026<\/span><span class=\"Apple-converted-space\"> <br \/><\/span><\/strong><\/span><\/p>\n<p><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><img decoding=\"async\" src=\"http:\/\/www.sslshopper.com\/assets\/images\/iis7-redirect\/iis7-redirect-http-to-https5.jpg\" \/><\/span><\/p>\n<p><span style=\"color: #000000; font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\"><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\">9. Click the<span class=\"Apple-converted-space\">\u00a0<\/span><\/span><strong style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;\">Custom error pages<\/strong><span style=\"font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; display: inline ! important; float: none;\"><span class=\"Apple-converted-space\">\u00a0<\/span>option and again browse for the redirectToHttps.htm file.<\/span><\/span><\/p>\n<p><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><img decoding=\"async\" src=\"http:\/\/www.sslshopper.com\/assets\/images\/iis7-redirect\/iis7-redirect-http-to-https6.jpg\" \/><\/span><\/span><\/p>\n<p>Here if you get an error in IIS saying &#8220;Lock violation&#8221; then you need to do the steps below.<\/p>\n<p style=\"margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; background-color: #ffffff; clear: both; word-wrap: break-word; color: #000000; font-family: Arial, 'Liberation Sans', 'DejaVu Sans', sans-serif; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-position: initial initial; background-repeat: initial initial;\">a. Open the file <span style=\"color: #ff0000;\">%windir%\\System32\\inetsrv\\config\\applicationHost.config<\/span> in Notepad. Run Notepad as the administrator if you&#8217;re having problems.<\/p>\n<p>You&#8217;ll see something like this:<\/p>\n<p><span style=\"color: #ff0000;\"><httpErrors lockAttributes=\"allowAbsolutePathsWhenDelegated,defaultPath\"><\/span><\/p>\n<p>Remove the <span style=\"color: #ff0000;\">,defaultPath<\/span> section and save.<\/p>\n<p style=\"margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; background-color: #ffffff; clear: both; word-wrap: break-word; color: #000000; font-family: Arial, 'Liberation Sans', 'DejaVu Sans', sans-serif; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-position: initial initial; background-repeat: initial initial;\">b. Also in the web.config file which is now created in your website root you will have to change the path from absolute to virtual <br \/>e.g. <br \/>Change below from<br \/><span style=\"color: #ff0000;\"><error statusCode=\"403\" subStatusCode=\"4\" path=\"c:\\inetpub\\HttpRedirect.htm\" responseMode=\"File\" \/><\/span><\/p>\n<p style=\"margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; background-color: #ffffff; clear: both; word-wrap: break-word; color: #000000; font-family: Arial, 'Liberation Sans', 'DejaVu Sans', sans-serif; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-position: initial initial; background-repeat: initial initial;\">To<\/p>\n<p style=\"margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; background-color: #ffffff; clear: both; word-wrap: break-word; color: #000000; font-family: Arial, 'Liberation Sans', 'DejaVu Sans', sans-serif; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-position: initial initial; background-repeat: initial initial;\"><span style=\"color: #ff0000;\"><error statusCode=\"403\" subStatusCode=\"4\" path=\"HttpRedirect.htm\" responseMode=\"File\" \/><\/span><\/p>\n<p style=\"margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; background-color: #ffffff; clear: both; word-wrap: break-word; color: #000000; font-family: Arial, 'Liberation Sans', 'DejaVu Sans', sans-serif; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-position: initial initial; background-repeat: initial initial;\">Now save the web.config.<\/p>\n<p>10. Test the site by going to http:\/\/www.yoursite.com and making sure it redirects<\/p>\n<p><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><span style=\"color: #666666; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; display: inline !important; float: none;\"><br \/><\/span><\/span><\/p>\n<p> ]]><\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you ever want to force your http traffic to https on IIS7 you can do the steps below. The steps here have been obtained after going through various forums and links which we tested and tried out. This worked for us so we&#8217;re putting it up here for everyone. How to redirect HTTP traffic [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[2],"tags":[],"_links":{"self":[{"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/posts\/278"}],"collection":[{"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=278"}],"version-history":[{"count":0,"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/posts\/278\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=278"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=278"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.jodohost.com\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=278"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}