Skip to content

Instantly share code, notes, and snippets.

HTTPS to HTTPS 301 Redirects with GoDaddy: Impossible

We had a client who needed to redirect an entire domain (we'll call it firstdomain.com) to a specific page on another domain (seconddomain.com/path/to/content) No problem, we thought. Their DNS was handled with GoDaddy, who offers a no-charge 301 forwarding service. A colleague of mine set up the redirect the way you'd expect, with all traffic to firstdomain.com being redirected to https://seconddomain.com/path/to/content. Then we encountered a problem.

We started getting ERR_CERT_COMMON_NAME_INVALID errors when we tried to visit firstdomain.com in desktop browsers. No redirect occurred. Some, but not all mobile browsers didn't have this issue. Stepping back to examine the problem, two mysteries became apparent to me:

  1. How does GoDaddy actually send a 301 status? You need a HTTP server for that.
  2. What is the purpose of the mysterious A record in the domain's DNS records that point to 184.168.131.241?

The mysterious A record in question was not ed

(function () {
function loadZendeskChat(callback) {
var zdscript = document.createElement('script');
zdscript.setAttribute('id','ze-snippet');
zdscript.src = 'https://static.zdassets.com/ekr/snippet.js?key=XXX-XXX-XXX-XXX';
(document.getElementsByTagName('body')[0]).appendChild(zdscript);
window.zdonload = setInterval(function(){
if(typeof zE !== "undefined" && typeof zE.activate !== "undefined") {