# SEO for developers: what to build into the code

> Most technical SEO problems are introduced in a pull request. Most can be caught there too.

- Page: https://liftup.tech/guides/seo-for-developers/
- Type: Guide
- Updated: 2026-11-20

## In short

The most useful SEO tools for web developers are the ones you can run in a release pipeline: curl for status codes and headers, Google Search Console for indexing, a crawler for internal links and a Lighthouse run for speed. Add generators for schema, hreflang and llms.txt. Then make the checks part of every deploy.

## Treat SEO as a set of testable requirements

Marketing teams ask for SEO as a list of wishes. Developers get better results by turning it into acceptance criteria. A page either returns a 200 or it does not. A canonical tag either points at the right URL or it does not. Everything below can be written as a test.

This page is for people who write the code. If you need the full audit list instead, use our [technical SEO checklist](https://liftup.tech/checklists/technical-seo-checklist/).

## The developer's SEO table

| Concern | Decision to make | How to verify |
|---|---|---|
| Rendering | Server-render or pre-render content that must rank; use client-side only for interactions | View the raw HTML source and check the main text is there |
| Status codes | 200 for live pages, 301 for permanent moves, 404 or 410 for gone, never 200 on an error page | curl -sI example.com/path/ and read the first line |
| Canonical URLs | One canonical per page, absolute, matching the version you want indexed | Search source for rel canonical on each template |
| Titles and descriptions | Generate unique values per page from data, not one site-wide string | Crawl and look for duplicates |
| Internal links | Use real anchor elements with href, not click handlers or buttons | Crawl without JavaScript and compare the link count |
| Robots and noindex | Staging blocked, production open, and the flag controlled by environment | Check headers and meta robots after each deploy |
| Redirects | Map old to new URLs one to one before a migration | Run the list through a bulk checker and count chains |
| Structured data | Output JSON-LD from the same data as the visible page | Rich Results Test on one URL per template |
| Performance | Reserve image space, defer scripts, ship less JavaScript | Field data for Largest Contentful Paint and Interaction to Next Paint |

If you want more detail, read our guide to [SEO for a GitHub Pages site](https://liftup.tech/guides/how-to-improve-seo-results-for-a-github-pages-website/).

## A release checklist you can add to your pipeline

1. **Block staging, open production**: Use an environment variable that sets noindex and robots rules on non-production builds, and a test that fails if production ever serves noindex.
2. **Snapshot before a template change**: Save titles, canonicals, headings and status codes for a sample of URLs, then diff them after deploy.
3. **Test redirects in CI**: Keep the redirect map as data. Test that each old URL answers 301 to the right target in one hop.
4. **Validate generated sitemaps**: Check that they list only canonical, indexable, 200 URLs and use the correct domain.
5. **Watch Search Console after release**: Check Pages (indexing), crawl stats and Core Web Vitals for the days after a deploy. Rollback is easier on day one than on day twenty.

## A bug we see often: staging rules reach production

A common sequence. A team builds on a staging domain with a blanket noindex. The code is promoted and the flag goes with it. Traffic falls over the next two weeks, but nobody connects it to the release.

Detection takes a minute. Run curl -sI against the live page and read the response headers for an X-Robots-Tag. View the source for a robots meta tag. Open the URL Inspection tool in Search Console and read whether indexing is allowed. Fix the flag, redeploy, then request indexing for the key URLs. This is an illustration of a pattern, not a client case.

## Framework notes

Next.js and similar frameworks give you server rendering and metadata functions, but defaults are not magic. Check each route type: dynamic routes, paginated lists and locale variants often miss canonicals or hreflang. For Next.js details, see our guide to [SEO in Next.js](https://liftup.tech/platforms/next-js-seo/). Single-page apps that render only in the browser can still be indexed, but rendering is queued and can lag, so pages that must rank should not depend on it.

## If you build a developer product

Documentation is usually the strongest search asset a developer tool has. Give every error message and API method a stable URL, keep versions clear with canonicals pointing to the current version, and write task-based pages such as how to authenticate with a given language. Searchers paste error text, so include it verbatim in headings or the first paragraph.

For a technical review of a live site, see our [technical SEO service](https://liftup.tech/services/technical-seo/) or send your stack through [our contact page](https://liftup.tech/contact/) for a fixed quote.

Related: [Ahrefs or Semrush](https://liftup.tech/compare/ahrefs-vs-semrush/), if you are choosing a paid SEO tool.

## Questions, answered

### Can Google index a JavaScript site?

Yes, Google renders JavaScript, but rendering can be delayed and other crawlers may not render it at all. Server-render content that must be found.

### Should I use a 301 or a 302 redirect?

Use 301 or 308 for permanent moves and 302 or 307 for temporary ones. For a migration, permanent redirects tell Google to transfer signals to the new URL.

### Do hash fragments in URLs work for SEO?

No. Content that depends on the part after the hash is not treated as separate pages. Use real paths for each view you want indexed.

### How many redirect hops are acceptable?

Aim for one. Chains slow users and waste crawl time, and Google follows only a limited number of hops.

### Who owns SEO on a team, developers or marketers?

Both, with a clear split. Marketers own topics and wording. Developers own rendering, URLs, performance and the release checks that stop regressions.

### Which SEO tool should a web developer start with?

Start with Google Search Console, because it shows what Google actually indexed. Add curl for status codes and redirects, and a crawler for broken links. Our free [schema markup generator](https://liftup.tech/tools/schema-markup-generator/), [hreflang generator](https://liftup.tech/tools/hreflang-generator/) and [llms.txt generator](https://liftup.tech/tools/llms-txt-generator/) cover the file formats.

## Sources

- [Google Search Central: JavaScript SEO basics](https://developers.google.com/search/docs/crawling-indexing/javascript/javascript-seo-basics)

## Related

- [Technical SEO checklist](https://liftup.tech/checklists/technical-seo-checklist/)
- [Technical SEO services for sites that will not index](https://liftup.tech/services/technical-seo/)
- [Next.js SEO: how to make a React site easy for Google to read](https://liftup.tech/platforms/next-js-seo/)

---

Get a fixed quote: https://liftup.tech/contact/ · email rohit@liftup.tech · WhatsApp +91 77689 10234 (https://wa.me/917768910234) · reply within one working day.
Source page: https://liftup.tech/guides/seo-for-developers/ (Liftup Technologies)
