Bot-served SDK reference pages (`/api/crawlers`) built every nav link from `request.url`. Behind the supabase.com/docs rewrite, that URL carries the internal docs host, so agents following the nav landed there instead of supabase.com. The canonical tag was already hardcoded to supabase.com. I switched the nav links to `PROD_URL`, the constant the markdown alternates and JSON-LD already use. **Note:** I chose absolute `PROD_URL` links over root-relative `/docs/...` hrefs because agents that convert the HTML to markdown or plain text lose the page's base URL. ## To test Tested on the PR preview: - [x] `curl -s -A 'Claude-User (claude-code/2.1.303; +https://support.anthropic.com/)' <preview>/docs/reference/javascript/select | grep -o 'href="[^"]*"' | sort -u | head`, expect every nav href to start with `https://supabase.com/docs/reference/javascript/` and none to point at the internal docs host - [x] Same request with a browser UA, expect the regular reference page (the browser route is untouched) ## Linear - fixes GROWTH-1341
Reference Docs
Supabase Reference Docs
Maintainers
If you are a maintainer of any tools in the Supabase ecosystem, you can use this site to provide documentation for the tools & libraries that you maintain.
DocSpec
We use documentation specifications which can be used to generate human-readable docs.
- OpenAPI: for documenting API endpoints.
- SDKSpec (custom to Supabase): for SDKs and client libraries.
- ConfigSpec (custom to Supabase): for configuration options.
- CLISpec (custom to Supabase): for CLI commands and usage.
The benefit of using custom specifications is that we can generate many other types from a strict schema (eg, HTML and manpages). It also means that we can switch to any documentation system we want. On this site we use Next.js, but on Supabase's official website, we use a custom React site and expose only a subset of the available API for each tool.
Contributing
To contribute to docs, see the style guide for how to write a page, and the developers' guide and contributing guide for repo mechanics. If you write with an AI coding agent, use the /write-the-docs skill to draft and /edit-the-docs to revise an existing page.