How I migrated my blog from Wordpress to self-hosted in a day
Since 2014, I have been writing on and off about cryptography, command prompt setups and product management from my blog - The Lonely Atoms. It started out as a managed Wordpress instance and is now a static site created using Jekyll and Amazon S3.
But I realised that it doesn’t make sense to create a separate brand instead of powering up my own. It would be much better to combine my blog posts into a personal website. Luckily for me ninadphadke.com was available. So one Saturday afternoon, I decide to get into it and migrate my blog from a custom domain to ninadphadke.com
Domain Registration
I’ve used Namecheap as my domain name provider since 2015. I’d recommend it to anyone. It’s secure, well-designed, cheap and not spammy. The options to add a new domain are straightforward. I purchased ninadphadke.com for around $1/month.
Static Site Generator
Since I shifted from my hosted Wordpress instance, I’ve been using Jekyll to create The Lonely Atoms site. I decided to stick to it when creating ninadphadke.com
Theme Selection
Jekyll has a very good selection of themes and it was easy to find one with a structure that had -
- A customisable home page with a good default design
- A top menu for navigation that I could easily add items to
- A way to add more pages (apart from Home, About and Blog)
- A decent set of functionality including SEO, Disqus Integration & Multiple Author support (for the future hopefully)
I ended up choosing the So Simple theme as my base theme. I then customized it to achieve a minimal look and good readability.
Migrating Posts
Since I was using Jekyll, I simply copied over existing posts from my _posts
folder in The Lonely Atoms to to _posts
in ninadphadke.com
Adding a Home Page
For now I’ve chosen to keep a one-line bio, my profile picture and a list of my posts on my home page. The plan is to show recent posts and most read posts on the home page and a Blog link in the top menu
Choosing a Hosting Provider
This is the decision that I spent the most time agonizing over. As I’ve said, my previous setup was hosted on S3.
For copying files in the
_site
folder in Jekyll over to S3, I was using a neat little Ruby Gem - S3_website
But I was still paying around $1/month for my S3 bucket. Plus, an Indian rule mandates AWS to take reauthorization every month. So, I evaluated and tried out both Github Pages and Netlify. I choose Netlify for three reasons -
- Setting Domain Redirection was much easier than Github Pages
- Getting an SSL certificate was free and took hardly 5 minutes
- I could setup a hook with a Bitbucket repo (and thus have my website remain private). A commit to this repo will automatically trigger a build by Netlify.
And that was that! I’m now live with an HTTPS website that costs me less than a dollar a month. And I did the whole thing in under 4 hours.