Publishing
Four publish modes, internal linking, and sitemap generation.
Overview
Publishing takes generated pages from the ready state and builds them as static HTML to your output directory. Every build operation triggers two automatic passes:
- Internal linking pass — Cross-links related pages within the same niche
- Sitemap rebuild — Regenerates
sitemap.xmlwith all published URLs
Additionally, each page receives JSON-LD structured data (Article + BreadcrumbList), canonical URLs, Open Graph meta tags, and your custom chrome (header/footer/CSS).
Publish Modes
| Mode | Behavior | Best For |
|---|---|---|
| Immediate | All ready pages are published at once | First batch, small sites, testing |
| Batched | Publish in fixed-size batches (e.g., 50 pages per batch) | Progressive rollout, indexing monitoring |
| Scheduled | Publish batches on a cron schedule (e.g., daily at 6am) | Drip content, consistent indexing signals |
| Manual | Pages stay in draft until you run contento publish <page-id> on each one |
Quality control, high-stakes content |
Immediate Publishing
Publishes all pages in the collection that have a ready status:
$ contento publish col_9d2f... --mode immediate Publishing 48 pages... ✓ Internal linking pass: 142 cross-links added ✓ Published 48 pages immediately.
Batched Publishing
Publishes a fixed number of pages per batch. Useful for monitoring indexing before publishing more:
$ contento publish col_9d2f... \ --mode batched \ --batch-size 25 Batched publishing started. 48 pages queued in batches of 25.
Scheduled Publishing (cron-driven)
The CLI doesn't run its own scheduler — drive scheduled batches with cron, GitHub Actions, or any other job runner that calls contento publish ... --mode batched --batch-size N on a recurring trigger. Cloud-scheduled publishing managed from the dashboard is on the Pro Team roadmap.
# cron: publish 25 pages every 6 hours
0 */6 * * * cd /path/to/site && contento publish col_9d2f... --mode batched --batch-size 25
Manual Publishing
In manual mode, each page must be individually approved before it goes live. This is useful for sensitive niches where you want to review every page:
$ contento publish col_9d2f... --mode manual Pages marked for manual review. List drafts with: contento collections show col_9d2f... --status draft
Internal Linking Pass
Every publish operation triggers an internal linking pass. The linker:
- Finds all published pages in the same niche as the newly published pages
- Identifies related pages based on subtopic similarity
- Injects 2–4 contextual links into the content body of each page
- Updates existing pages that should link to the newly published pages
This creates a web of internal links that distributes link equity across your pages and helps search engines discover and crawl all content. See Internal Linking for the full guide.
Sitemap & robots.txt
Each contento build regenerates sitemap.xml and robots.txt in the output directory alongside the rendered HTML. The sitemap includes:
<loc>— Full URL of each published page<lastmod>— Publication timestamp<changefreq>— Set tomonthlyby default<priority>— Default0.7per URL
The generated robots.txt allows all crawlers and points them at https://<your-domain>/sitemap.xml. Sitemap-index splitting for projects above 50,000 URLs is on the roadmap.
CLI Commands
| Command | Description |
|---|---|
contento publish <collection-id> [--mode] [--batch-size] | Publish pages (modes: immediate, batched, manual; pair with cron for scheduled releases) |
contento build <project-id> --output <dir> | Build published pages to static HTML |