Custom Domains
All books on Gitbook.com are served under http://{author}.gitbooks.io/{book}/
, the book’s content is available at http://{author}.gitbooks.io/{book}/content/
.
But you can configure your book to use a custom domain name (a free feature on GitBook). Domain names can be used for your homepage or content (or both).
Adding a custom domain is easy.
On GitBook.com
Go to your book’s Settings tab and then click on Domains. Then simply enter your domain and save.
With your domain registrar
To finish the setup you will need to make a few changes with your domain registrar:
Login to your domain registrar and find the page that allows you to add/edit host records. That page is often found in your settings under
Edit DNS
,Host Records
orZone File Control
.Set the
www
record to a CNAME and set the URL field to:www.gitbooks.io
.To redirect the naked domain (
yourdomain.com
) towww.yourdomain.com
, you’ll need to enable “domain forwarding”. This is often found under ‘Forwarding’, ‘URL Forwarding’ or ‘URL Redirect’.
That’s all ! It might take a few hours for the DNS to propagate.