May 6, 2024

How I failed to properly transfer this website's domain

I used to run my blog at a different domain, ribice.ba .For personal reasons and other projects that I now host on this domain, I decided to transfer my programming blog to dev.ribic.ba. As I had no experience with domain migrations, I just set up the 301 redirect and submitted this change to Google Search Console. It went horribly wrong.

I have been running this blog since 2017. I’ve written about various topics, but the majority of my posts are programming related.

Some of my posts went viral on Reddit and HackerNews, which brought a lot of traffic to my blog. It averaged around 10k unique visitors per month. (~300 per day). I was quite happy with the traffic, as I was writing mostly for myself and to document my programming journey.

Early 2023 I decided to transfer my blog to a new domain. I wanted to host my own email, have another personal blog that’s not programming related, and host a few other projects.

I set up the 301 redirect from ribice.ba to dev.ribic.ba - I host my blog on Netlify so it was just a matter of updating the _redirects file.

https://dev.ribic.ba https://dev.ribic.ba
https://www.dev.ribic.ba https://dev.ribic.ba
http://dev.ribic.ba/* https://dev.ribic.ba/:splat 301
https://dev.ribic.ba/* https://dev.ribic.ba/:splat 301
http://www.dev.ribic.ba/* https://dev.ribic.ba/:splat 301
https://www.dev.ribic.ba/* https://dev.ribic.ba/:splat 301

After this, I submitted the change to Google Search Console. I assumed most of the traffic would move to the new domain in a few weeks. I was wrong.

The traffic dropped to nearly zero. I was getting around 10-20 visitors per day. I thought it was just a temporary issue, but it never recovered.

As my blog does not bring any revenue and I write mostly for myself, I didn’t bother to investigate further. I still feel bad about it, as I lost a lot of traffic and potential readers. I’m not sure what went wrong, but I learned my lesson. I should’ve done more research and asked for help from someone who has experience with domain migrations.

Weekly traffic before (used Google Analytics):

Weekly traffic after (using Plausible):

2024 © Emir Ribic - Some rights reserved; please attribute properly and link back. Code snippets are MIT Licensed

Powered by Hugo & Kiss.