Skip to content

Commit 33c6aac

Browse files
committed
Update 20-seo.qmd
1 parent b40cf12 commit 33c6aac

1 file changed

Lines changed: 32 additions & 16 deletions

File tree

user_guide/20-seo.qmd

Lines changed: 32 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@ versions: ">=0.2"
88

99
# SEO Optimization
1010

11-
Great Docs includes comprehensive search engine optimization (SEO) features to help your documentation rank well in search results. These features are enabled by default and work automatically when you build your site.
11+
Great Docs includes comprehensive search engine optimization (SEO) features to help your
12+
documentation rank well in search results. These features are enabled by default and work
13+
automatically when you build your site.
1214

1315
## What's Included
1416

@@ -77,11 +79,13 @@ great-docs seo --json
7779
}
7880
```
7981

80-
The command exits with code `1` if critical issues are found, making it easy to fail CI builds on SEO problems.
82+
The command exits with code `1` if critical issues are found, making it easy to fail CI builds on
83+
SEO problems.
8184

8285
## Configuration
8386

84-
All SEO settings live under the `seo` key in `great-docs.yml`. Here's the full configuration with defaults:
87+
All SEO settings live under the `seo` key in `great-docs.yml`. Here's the full configuration with
88+
defaults:
8589

8690
```{.yaml filename="great-docs.yml"}
8791
seo:
@@ -122,11 +126,13 @@ seo:
122126
default_description: null # Falls back to package description
123127
```
124128

125-
Most users won't need to change these defaults as they're optimized for typical Python documentation sites.
129+
Most users won't need to change these defaults as they're optimized for typical Python documentation
130+
sites.
126131

127132
## Sitemap Configuration
128133

129-
The sitemap tells search engines about all your pages and how often they change. Great Docs generates different priorities and change frequencies based on page type.
134+
The sitemap tells search engines about all your pages and how often they change. Great Docs
135+
generates different priorities and change frequencies based on page type.
130136

131137
### Page Types
132138

@@ -167,7 +173,8 @@ seo:
167173

168174
## Robots.txt Configuration
169175

170-
The `robots.txt` file tells search engine crawlers which pages to index and where to find your sitemap.
176+
The `robots.txt` file tells search engine crawlers which pages to index and where to find your
177+
sitemap.
171178

172179
### Default Behavior
173180

@@ -220,11 +227,13 @@ seo:
220227

221228
## Canonical URLs
222229

223-
Canonical URLs tell search engines which version of a page is the "official" one, preventing duplicate content issues when your site is accessible via multiple URLs.
230+
Canonical URLs tell search engines which version of a page is the "official" one, preventing
231+
duplicate content issues when your site is accessible via multiple URLs.
224232

225233
### Auto-Detection
226234

227-
Great Docs automatically generates canonical URLs based on your GitHub repository. If your repo is `github.com/username/repo`, the canonical base URL will be:
235+
Great Docs automatically generates canonical URLs based on your GitHub repository. If your repo is
236+
`github.com/username/repo`, the canonical base URL will be:
228237

229238
```
230239
https://username.github.io/repo/
@@ -244,7 +253,8 @@ The trailing slash is important (Great Docs will add it if missing).
244253

245254
## Page Titles
246255

247-
Great Docs applies a consistent title template to all pages, improving brand recognition in search results.
256+
Great Docs applies a consistent title template to all pages, improving brand recognition in search
257+
results.
248258

249259
### Default Template
250260

@@ -272,7 +282,8 @@ seo:
272282

273283
## Structured Data (JSON-LD)
274284

275-
Great Docs injects [JSON-LD](https://json-ld.org/) structured data into your pages, enabling rich search results with additional context about your software.
285+
Great Docs injects [JSON-LD](https://json-ld.org/) structured data into your pages, enabling rich
286+
search results with additional context about your software.
276287

277288
### What Gets Injected
278289

@@ -314,14 +325,15 @@ seo:
314325

315326
## Meta Descriptions
316327

317-
Meta descriptions appear in search result snippets. Great Docs automatically generates them from your page content.
328+
Meta descriptions appear in search result snippets. Great Docs automatically generates them from
329+
your page content.
318330

319331
### Auto-Generation
320332

321333
For each page, Great Docs extracts a description from:
322334

323-
1. The first meaningful paragraph in the page content
324-
2. Falls back to the default description if no suitable content is found
335+
1. the first meaningful paragraph in the page content
336+
2. falls back to the default description if no suitable content is found
325337

326338
### Setting a Default Description
327339

@@ -347,7 +359,8 @@ description: "How to install My Package using pip, conda, or from source."
347359

348360
## Noindex for Internal Pages
349361

350-
Some pages shouldn't appear in search results. Great Docs automatically adds `noindex` directives to internal pages like the Skills page.
362+
Some pages shouldn't appear in search results. Great Docs automatically adds `noindex` directives to
363+
internal pages like the Skills page.
351364

352365
### Manual Noindex
353366

@@ -411,11 +424,14 @@ seo:
411424
base_url: https://docs.myproject.com/
412425
```
413426

414-
And ensure your DNS is configured correctly (see [Adding a Custom Domain](../recipes/add-custom-domain.qmd)).
427+
And ensure your DNS is configured correctly (see
428+
[Adding a Custom Domain](../recipes/add-custom-domain.qmd)).
415429

416430
## Next Steps
417431

418-
Good SEO makes your documentation discoverable. Great Docs handles the technical foundations (sitemaps, canonical URLs, meta tags) automatically, so you can focus on writing clear titles and descriptions.
432+
Good SEO makes your documentation discoverable. Great Docs handles the technical foundations
433+
(sitemaps, canonical URLs, meta tags) automatically, so you can focus on writing clear titles and
434+
descriptions.
419435

420436
- [Social Cards](social-cards.qmd) controls how links appear when shared on social platforms
421437
- [Deployment](deployment.qmd) covers publishing to GitHub Pages with SEO settings applied

0 commit comments

Comments
 (0)