DEV Community

Cover image for 10 HTML Tags for SEO๐Ÿ”

10 HTML Tags for SEO๐Ÿ”

Sampad Sarker on September 25, 2022

1.Use Title Tags <title>Title of the webpage ...... </title> Your content is labeled in this way, and search engines interp...
Collapse
 
mrcaidev profile image
Yuwang Cai

I recently read the documentation of Open Graph, and I'm confused about the way DEV.TO add og:* to their meta tags, on the page of a post article.

This is how DEV.TO adds OG meta tags to the post article page:

How DEV.TO adds OG meta tags to the post article page

But actually when I finished reading the OG documentation, I think meta tags like og:title, og:description should be relative to the post itself, rather than information of the whole DEV.TO site.

I'm a beginner to SEO so would anyone explain this to me๐Ÿค”

Collapse
 
cicirello profile image
Vincent A. Cicirello

Are you sure your screenshot is of the head of a page for a post? And not for the dev.to homepage? I just checked head of a page for one of my posts and the og and twitter tags correspond to the post as you'd expect.

Collapse
 
mrcaidev profile image
Yuwang Cai

I found something interesting: When I first enter a page for a post, the meta tag is all about DEV.TO, but after I click on the refresh button, the meta tags update to the content of the post...

Thread Thread
 
cicirello profile image
Vincent A. Cicirello

That is interesting. I wonder if it is something browser specific causing that behavior, perhaps in combination with their CMS. Viewing the source in Chrome on Android showed header tags as expected. I might check it out again later on a desktop.

Thread Thread
 
mrcaidev profile image
Yuwang Cai

I use Edge on Windows and has not yet figured out a convincing explanation๐Ÿค”

Thread Thread
 
fic_stojkovski profile image
Filip Stojkovski • Edited

This is probably because the meta og tags are set on backend and the DEV.TO is probably single page application and never re-set after the initial page load. Meta og tags are used so social media like twitter/facebook etc. can "beautify" the post of copied link. In reality you don't need some of the meta tags to be updated dynamically on SPAs as long as it is properly crawled by the robots when accessed.
Note: This is my presumption and view of this "problem"

Thread Thread
 
cicirello profile image
Vincent A. Cicirello

You might be right (I haven't been curious enough to look at the forem repository for the source code). However, I also haven't been able to recreate the issue described here. I've gone to the page of one of my own posts on both Chrome and Edge on Windows 10, as well as on Chrome on Android, and in all 3 cases inspecting the source of the post page, I find the OG tags for the post (as you'd expect) and not for the site. I'm guessing that the behavior that they saw might depend upon how one navigates to a post page.

Thread Thread
 
mrcaidev profile image
Yuwang Cai

๐Ÿ‘Makes sense

Collapse
 
ashleyjsheridan profile image
Ashley Sheridan

Have to chime in on the alt "tags". Firstly, it's an attribute value, not a tag.

Second, it's meant as an alternative to the image, such as on slow connections where the image doesn't load, or for screen readers. It's absolutely not for the purposes of SEO. Stuffing keywords into image text is just a plain bad experience all round.

Collapse
 
sampadsarker profile image
Sampad Sarker

of course alt is not a tag
THANKS

Collapse
 
lucaargentieri profile image
Luca Argentieri

Thank you for your post.
Maybe you could talk about the manifest or create a post about it. ๐Ÿ”ฅ

Collapse
 
mrepol742 profile image
Melvin Jones Repol

Adding open graph meta tag can also help

ogp.me/

Collapse
 
robsonmuniz16 profile image
Robson Muniz

Good Content, thanks for sharing it!

Collapse
 
dhruvjoshi9 profile image
Dhruv Joshi

Super helpful! Thanks!