How to move a Ghost blog

How to move a Ghost blog
Photo by Handiwork NYC / Unsplash

In the past I had way too many domains, which often resulted in actually moving porjects from left to right and back. Now I try to be more concise with the choice of my domains, but it still doesn't always work out right away.

Update your domain's DNS


The first step is adjusting the domains DNS. Point your new domain to your server. This is done by creating an A record in your domain provider pointing to your server's IP address.


Edit your config file in nginx


In the second step your need to login onto the server via SSH and edit the site URL within Ghost. Change your directory to the folder where Ghost is located e.g. /var/www/ghost and run

ghost config url https://yournewdomain.com


Run setup nginx


Now you should run ghost setup nginx. This will set up some server-level files for serving your Ghost site for the domain.


Create an SSL certificate


Run ghost setup ssl. This will go through the Let's Encrypt process for creating a fresh and free SSL certificate. You will need to input an email address during the installation.


Restart Ghost


Run ghost restart to reload the Ghost software (this refreshes all the links across your site).

Check the certificates in folder: /etc/letsencrypt
ls /etc/letsencrypt

Certificate was generated as example.com_ecc

Then go to /etc/nginx/sites-available
Find file for the site: example.com-ssl.conf

Update the paths on lines starting with: ssl_certificate by adding _ecc:
ssl_certificate /etc/letsencrypt/example.com_ecc/fullchain.cer;
ssl_certificate_key /etc/letsencrypt/example.com_ecc/example.com.key;

Hendrik Michaelsen

Hendrik Michaelsen

Software Engineer & Entrepreneur @ work | Building innovative solutions in public and bringing ideas to life.