Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Had an seo report saying that alot of my pages dont have doctype declared? How do i fix this? Do i put <doctype > html5<doctype/)
Hi @Vvel
Aibek is here from Speedimize.io
Usually the doctype is declared by default. In any case, you can specify as below in theme.liquid.
https://www.w3schools.com/tags/tag_doctype.asp
In short, at the beginning of theme.liquid, write:
<!DOCTYPE html>
I know how add it but I don't know what specific file to put it in. My report says 87 pages dont have it. Homepage, collections, blogs, and pages.
Can you share with us URL of your shop?
So we can check this and find solution for you.
inniti wear dot com
Hey @Vvel
https://prnt.sc/126twcu -doctype not specified. Usually, in each theme, the doctype is specified at the beginning of theme.liquid. At the very beginning of the theme.liquid doctype is not registered.
theme.liquid is a global layout. Enter the doctype in this file.
If you wish, we can help you with this.
We can send you request via Shopify Partners.
<!doctype html> is has already been there.
this is what the couple of first lines look like...
{% render 'breadcrumbs' %}
{% capture content %}
<!DOCTYPE html>
<html>
<!--[if lt IE 7 ]><html class="ie ie6" lang="{{ shop.locale }}"> <![endif]-->
<!--[if IE 7 ]><html class="ie ie7" lang="{{ shop.locale }}"> <![endif]-->
<!--[if IE 8 ]><html class="ie ie8" lang="{{ shop.locale }}"> <![endif]-->
<!--[if IE 9 ]><html class="ie ie9" lang="{{ shop.locale }}"> <![endif]-->
<!--[if (gte IE 10)|!(IE)]><!--><html lang="{{ shop.locale }}"> <!--<![endif]-->
<head>
<!-- Added by AVADA SEO Suite -->
{% include 'avada-seo' %}
<!-- /Added by AVADA SEO Suite -->
<meta name="google-site-verification" content="3D5I-_AxcVOTa5N8-Aa80SFKTQxzl3GkWsFxoD68G0M" />
<meta charset="utf-8">
<meta http-equiv="cleartype" content="on">
<meta name="robots" content="index,follow">
Hi. Did you solve this? i also get message that doctype is not declared but i have in my theme.liquid and it is also in source code of page visible
June brought summer energy to our community. Members jumped in with solutions, clicked ...
By JasonH Jun 5, 2025Learn how to build powerful custom workflows in Shopify Flow with expert guidance from ...
By Jacqui May 7, 2025Did You Know? May is named after Maia, the Roman goddess of growth and flourishing! ...
By JasonH May 2, 2025