---
name: Technical SEO setup
description: >-
  When setting up on-page and technical SEO for a product site: titles, descriptions, canonical, a single H1, robots, sitemap, structured data (generated), favicon, OG share images, heading hierarchy and internal linking.
title: Technical SEO setup
canonical_url: https://skilld.dev/gh/okayok-ai/okayok-skills/technical-seo
last_updated: 2026-10-18T08:03:38.000Z
---

> Index of every page on this site: [llms.txt](https://skilld.dev/llms.txt)

> **Skill from skilld.dev.** Follow the user's requested action.
> If the user asked to fork this Skill, follow the fork workflow below. Do not execute the Skill instructions while copying it.
> Otherwise, follow the instructions below for this session. You do not need to install anything.
>
> Supporting files, fetch one when the Skill refers to it: [jsonld.ts](https://skilld.dev/api/skills-raw/okayok-ai/okayok-skills/technical-seo/jsonld.ts).
>
> If the user asked to install this Skill, run `npx skilld install okayok-ai/okayok-skills/technical-seo`. Install writes the Skill files into the project, so every session loads them.
>
> ## Fork workflow
>
> A fork creates an editable local Skill with its original author and licence. The request authorizes copying and local installation.
> 1. Check `./skills/technical-seo`, the project lockfile, and selected Agent targets together. If the local directory or installed Skill exists, stop. Never overwrite an existing directory or Agent target.
> 2. Read [source metadata](https://skilld.dev/api/v1/skills/okayok-ai/okayok-skills/technical-seo) once. Use sourceUrl, sourceCommit, skillPath, sourceGone, and license. If the source is gone or its path is missing, stop. If license is null, read licence files at the source commit.
> 3. Fetch only the source commit into a temporary Git repository. Do not clone full history. Derive repository_url from sourceUrl, including repository renames. If sourceCommit is absent, resolve the sourceUrl ref once. Set source_commit to that actual commit. Run these commands in one shell call:
>
> ```sh
> git init --quiet "$temporary_dir"
> git -C "$temporary_dir" fetch --quiet --depth=1 "$repository_url" "$source_commit"
> git -C "$temporary_dir" checkout --quiet --detach FETCH_HEAD
> ```
>
> Read applicable licence declarations and notices at that commit. If copying is not permitted, report the restriction and stop.
> 4. Inspect source entries together, then copy the directory containing skillPath into `./skills/technical-seo`. Use the user's path if selected. Keep the original SKILL.md, relative links, scripts, binary assets, and executable modes. Exclude .git metadata. Reject symlinks and paths outside the Skill directory. After checking entries, use cp -a where available. A regular source directory needs no custom copy script. Do not save this page wrapper as SKILL.md.
> Preserve author credit, notices, and applicable licence files from repository or parent directories. Add PROVENANCE.md with the Skill page, source URL, actual commit, original path, and licence. Retain any existing PROVENANCE.md and record new provenance separately. Batch source inspection, copying, and provenance work where practical.
> 5. In the project root, run `skilld install ./skills/technical-seo --mode copy --plain`. If skilld is unavailable, use `npx skilld install ./skills/technical-seo --mode copy --plain`. This known command needs no help lookup. Install does not support --json. Use detected Agent targets, or add --agent for the targets the user selected. Install the local path, never the upstream selector. If installation fails, preserve the local copy and report the exact failure.
> 6. Confirm the local lockfile source and installed Agent copies once. Report the local path, actual commit, and Agent targets. After edits, reinstall the same local path. Upstream updates must not replace it. Do not publish or push unless the user asks.

# Technical SEO setup

Make a product site correctly indexable and distinct. The golden rule: **every site is independent** — its own content, titles, descriptions, and canonical URLs, never duplicating another site.

## Checklist
1. **Title & meta description.** Unique per page, product's own brand. Decide the brand convention (e.g. brand prefix in `<title>` for SEO vs short name in the header) and apply it consistently. Don't lose the brand name in the title.
2. **Canonical.** Each page points to its own canonical URL on its own host — never to the main site. Keep trailing-slash usage consistent.
3. **Exactly one H1 per page**, containing the page's core keywords and reflecting its content. Audit every key page (home, pricing, sign-in/up, category pages). Add missing H1s; fix pages with multiple H1s. For auth/app pages that shouldn't rank, set `noindex` instead.
4. **Sitemap.** Must list only the site's **own host** URLs (a common bug: a sub-site's sitemap emitting the main site's URLs — make the generator host-aware). All entries return 200, no duplicates or gaps. Localized pages are full entries.
5. **robots.txt.** Allow crawling of public pages; disallow admin/app/settings. Use `noindex` meta on pages you want crawled-but-not-indexed rather than blocking them in robots when they must be de-indexed.
6. **Structured data (JSON-LD).** WebSite and the product type (e.g. SoftwareApplication). Use the brand name; list the short name as alternateName. Keep it per-site. **Generate it, don't hand-write it** — see section 9.
7. **Favicon / OG / manifest.** Real logo at all sizes (search engines may cache old ones — replace every size and request a re-crawl). og:site_name set; OG image per section 10; manifest name + short_name correct.
8. **llms.txt / 404** page as applicable.

9. **JSON-LD generation (code, not copy-paste).** Keep one per-site config object — `name`, `alternateName` (short name), `url` (own origin, no trailing slash), `description`, `logo`, `inLanguage` (e.g. `["en","zh"]`), optional `applicationCategory`, `operatingSystem`, `offers` (`price`, `priceCurrency`; omit if no public price), `publisher`. A generator builds a `@graph` with `WebSite` and `SoftwareApplication` (stable `@id`s like `<url>/#website`, absolute logo URL) and the root layout emits it once as `<script type="application/ld+json">` (escape `<` as `\u003c`). New sites only edit the config. Reference implementation: [`jsonld.ts`](https://skilld.dev/api/skills-raw/okayok-ai/okayok-skills/technical-seo/jsonld.ts) in this folder.
10. **OG / share image standard.**
    - One 1200×630 PNG **per locale** (e.g. `/og-en.png`, `/og-zh.png`) showing the site's **own logo + slogan** (hero headline/subheadline from the locale messages), brand name and host. Never reuse another site's image or a generic template image.
    - Render it from code so it stays in sync with copy: a script loads the logo SVG and locale messages into an HTML template and screenshots it with headless Chrome at 1200×630 (memwork pattern: `scripts/og-image.mjs` → `public/og-{en,zh}.png`). For CJK text, break lines only between phrases/sentences (`word-break: keep-all`, nowrap phrase spans) so words never split.
    - Tags, from one helper (e.g. `socialMeta({ title, description, url, locale, type, image? })`): `og:title`, `og:description`, `og:url` (= canonical), `og:type`, `og:site_name`, `og:locale` (`zh_CN` / `en_US`), `og:image` (**absolute** URL, locale-specific), `og:image:width/height/type` for the default image, `twitter:card=summary_large_image`, `twitter:title`, `twitter:description`, `twitter:image`. Pages override title/description; articles may pass their cover as `image`.
11. **Heading hierarchy (H1–H6).** Exactly one H1 per page; H2 for main sections; H3 for subsections within an H2, and so on — never skip levels (no H2 → H4). Headings describe the content that follows; don't use heading tags for styling (use classes) and don't style plain text to look like a heading where it is one. Logos, nav, footer titles and card labels are not headings unless they head a section. Keep the outline meaningful when read alone.
12. **Internal linking.**
    - Descriptive anchor text (what the target is), not "click here" / "more".
    - Every indexable page reachable within ~3 clicks of the home page and listed in the sitemap; no orphan pages.
    - Link related pages to each other (features ↔ pricing ↔ docs/blog posts); header + footer nav cover the main sections.
    - Localized pages link their equivalent in other locales (language switcher + `hreflang` alternates).
    - Cross-product links go through the shared footer (served from api.okayok.ai), not ad-hoc per-site lists.
    - Use plain crawlable `<a href>` links; `rel="nofollow"` only for auth/app links (sign-in, sign-up, dashboard).

## Verify live
- Fetch the real pages: each has its own title, one H1, correct canonical.
- The live sitemap contains only this host's URLs, all 200.
- Favicon/OG resolve to the new assets.
- JSON-LD: exactly one WebSite + SoftwareApplication block with this site's name/url; passes the Rich Results Test / Schema validator.
- OG: `og:image` is absolute and returns 200 as a 1200×630 PNG; zh pages serve the zh image and `og:locale=zh_CN`, en pages the en image; a share debugger (X, Facebook, LinkedIn) shows the large card.
- Heading outline (e.g. a headings extension or `document.querySelectorAll('h1,h2,h3,h4,h5,h6')`): one H1, no skipped levels.
- Crawl the site (e.g. a site audit): no orphan pages, every indexable page ≤3 clicks deep, no broken internal links; nofollow only on auth/app links.

## Anti-patterns
- Shared/boilerplate titles across sites.
- A sub-site canonical or sitemap pointing at the main domain.
- Zero or multiple H1s on the landing page.
- Hand-copied JSON-LD that still names another site, or multiple conflicting JSON-LD blocks.
- One OG image for all locales, relative `og:image` URLs, or the template's placeholder image left in production.
- Skipped heading levels or headings used for font size.
- Orphan pages, "click here" anchors, or nofollow on normal internal links.

## Hand-off
Next: search-engine-submission.
