SEO Best Practices
Optimize your theme for search engines to increase visibility.
Good SEO starts with a well-structured theme. By using the right tags and data, you can help search engines understand your content better.
Use Semantic HTML
Use tags like `<header>`, `<footer>`, `<main>`, `<article>`, and `<nav>` to give structure to your page. Use an `<h1>` for the main title (blog title on homepage, post title on post pages) and `<h2>`, `<h3>` for subheadings.
Dynamic Meta Tags
Blogger automatically handles the `<title>` tag well with `data:blog.pageTitle`. You can also add a dynamic meta description.
Code Examples
12345<b:if cond='data:view.isPost'> <meta expr:content='data:post.snippet' name='description'/><b:elseif cond='data:view.isHomepage'/> <meta expr:content='data:blog.description' name='description'/></b:if>Pro Tip
Blogger automatically generates a `sitemap.xml` and allows you to set a custom `robots.txt` in the settings, so you don't need to handle those in the theme.
Was this lesson helpful?
Have feedback, found an issue, or have a suggestion? Let us know!
