You can’t “export” the files from dbt Cloud, but it’s easy to rebuild them with dbt docs generate
.
The docs site is a static SPA, so it’s pretty easy to host anywhere – you just copy the artifacts from dbt docs generate
into S3 or another hosting provider. Official docs are here.
I’ve used GitHub pages for this, since all you have to do is copy the artifacts into a subdirectory in your project, and GitHub will automatically host them. See this package for an example. I have make
command to generate the docs and move them from the /integration-tests/target
directory to the /docs
directory. Then you can configure GitHub Pages in your repo settings to serve the /docs
directory. Here’s the config:
If you need auth, you can use Netlify: Publishing dbt Docs to Netlify - Show and Tell - dbt Community Forum (getdbt.com)