Deploying a Hexo site on Vercel is super easy!
Let’s remind some basics:
- Hexo is a static site generator. Meaning that you can generate a pure HTML site that does not rely on a backend server (PHP, nodejs, …)
- Vercel is a bit like Netlify, it allows you to host your static site, and offers you features to make it more dynamic (authentication, lambda functions)
At Vercel, they made a great job at making the onboarding easy and complete.
Your Hexo site sources must be hosted on GitHub (also works with GitLab and Bitbucket).
Once you are ready, go to https://vercel.com
Choose the GitHub login (button “Continue with GitHub”)
Then click on “Continue” below “Import Git Repository”.
Paste your git repository url:
Vercel will ask you if it’s your repository or not. Say Yes.
It will redirect you to GitHub Authorization screen, where you need to allow Vercel to have access to your repository.
Once you are done, Vercel will deploy your site to their domain: https://my-site.vercel.app
You can easily configure a domain to point to your Vercel deployment via the Menu: My Project > Settings > Domains where they ask you to provide the domain name you want to define, and then you have to add a CNAME to your DNS
And voila :)
For me, the result is here: