Is it possible to duplicate headers? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

Is it possible to duplicate headers?

As far as I know, the headers h1, h2, and so on can only be in the code 1 time. Or are there any new rules?

8th May 2020, 10:16 AM
Михаил Соболев
Михаил Соболев - avatar
4 Answers
+ 3
I was taught that there should only ever be one <h1> tag, so search engine crawlers can find the title of your page more easily. There were never any rules about the other tags. I'm not sure if it still matters. Google says it doesn't matter to them, but there are other crawlers out there. Better be safe and do only one <h1> per page, to me it makes sense that a page should have only one title. But my info is over 10 years old so maybe don't listen to me.
8th May 2020, 10:42 AM
Schindlabua
Schindlabua - avatar
+ 3
Михаил Соболев Hey, no :)) You can use them as many as you want.
8th May 2020, 10:24 AM
Arb Rahim Badsa
Arb Rahim Badsa - avatar
+ 2
Schindlabua Nice info :)) But I think search engines now use <title> tag for that. 🤔 I am also not sure.
8th May 2020, 10:45 AM
Arb Rahim Badsa
Arb Rahim Badsa - avatar
+ 2
Arb Rahim Badsa I just now saw a blog post that said the first <header> tag on the page is now used for similar purposes. But yeah no clue. I don't have to do SEO thankfully.
8th May 2020, 10:47 AM
Schindlabua
Schindlabua - avatar