</a></h2><p>I assume you are using Luke Smith’s theme - Lugo, if you are not, you’d have to find these files yourself (e.g. search using vscode).</p>
<h3id="setting-a-global-meta-description">Setting a global meta description <aclass="anchor"href="#setting-a-global-meta-description">
</span></span><spanstyle="display:flex;"><span><spanstyle="color:#a6e22e">description</span> = <spanstyle="color:#e6db74">"The global meta description of your website"</span>
</span></span><spanstyle="display:flex;"><span><spanstyle="color:#f92672">description</span>: <spanstyle="color:#ae81ff">The global meta description of your website</span>
<li>Add or change the meta description line with the following</li>
</ol>
<divclass="highlight"><pretabindex="0"style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><codeclass="language-html"data-lang="html"><spanstyle="display:flex;"><span><<spanstyle="color:#f92672">meta</span><spanstyle="color:#a6e22e">name</span><spanstyle="color:#f92672">=</span><spanstyle="color:#e6db74">"description"</span><spanstyle="color:#a6e22e">content</span><spanstyle="color:#f92672">=</span><spanstyle="color:#e6db74">"{{ if .Page.Params.description }}{{ .Page.Params.description }}{{ else if .Summary}}{{ .Summary }}{{else}}{{ .Site.Params.description}}{{ end }}"</span>/>
</span></span></code></pre></div><p>And now if you start your Hugo server locally with <code>hugo serve --noHTTPCache</code> and you right click on your page -> View Page Source -> Search for the meta description tag. It should match what you left in the config file.</p>
<h3id="replacing-the-global-description-with-a-custom-one">Replacing the global description with a custom one <aclass="anchor"href="#replacing-the-global-description-with-a-custom-one">
</span></span><spanstyle="display:flex;"><span><spanstyle="color:#f92672">description</span>: <spanstyle="color:#e6db74">"Your custom description for this page"</span>
</span></span></code></pre></div><p>Following these steps would guarantee that you have a meta description for everypage with the ability for creating a custom one whenever you need it!</p>
<divid="nextprev">
<ahref="/blog/multiple-index-pages-in-hugo/"><divid="prevart">Previous:<br>Multiple Index Pages in Hugo</div></a>
<ahref="https://vodoraslo.xyz/">Homepage</a><br><br><ahref="/index.xml"><imgsrc="/rss.svg"style="max-height:1.5em"alt="RSS Feed"title="Subscribe via RSS for updates."></a>