1

Currently I have an API setup where I fetch values from to populate items on the page. However, after reading many mixed voices about whether or not Javascript is executed by a crawler, I was wondering if I should change my backend to use template engines.

To clarify, my server runs a Node.js backend, and I could use something like React instead.

This is fueled by a comment I just received which told me that Google puts emphasis on internal links to other pages, not exactly all in the Sitemap:

"...Google puts a much higher focus on discovering pages via internal links."

Comment by Trebor

Is this true? Do I need to render the site in the backend before it even reaches the crawlers?

Also, I think I should mention that this site is a blog, and so I have a lot of blog pages that need to be indexed, which hopefully should be opened by Google. However, these are dynamically added to the site which makes me unable to use static html, instead I add the blog pages to a list on the homescreen by an AJAX call.

1 Answer 1

1

The comment is true, Google does not typically index or rank pages just because they are found in a sitemap. Google will discover, index, and rank pages when they get links from other pages. Sitemaps are next to useless when it comes to SEO. See The Sitemap Paradox

That doesn't necessarily mean that you need to render your site on the back end. Googlebot now executes JavaScript and scans the document object model (DOM) for links. As long as your JavaScript is creating <a href=...> nodes in your pages, Googlebot will be able to crawl your site, find all your pages, pass PageRank, index your pages, and rank them well.

That being said, server side rendering (SSR) usually dramatically speeds up the process. Google can take extra weeks or months to index a site and process updates to your site when Googlebot has to render the JavaScript. In addition, other search engines (like Bing, Baidu, and Yandex) won't be able to index a site that requires JavaScript.

Most single page application (SPA) frameworks have some sort of mechanism to pre-render your site on the server. If you are using one of these frameworks (like Angular or React), you should be able to find a way to run the JavaScript server side to make it more accessible to bots.

1
  • Perfect! Thanks for the help :) Commented Jan 4, 2022 at 18:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.