#ReactForSEO
Explore tagged Tumblr posts
katyslemon · 4 years ago
Text
Quick Summary
Acknowledge the challenges that React applications face on the SEO part. To be more precise, you will find a brief on how React is compatible with SEO practices. As a result, you will also know how Google crawls to these types of ReactJs websites. Generally, a page undergoes several processes before indexing. It’s all good unless Googlebot faces problems crawling the content. Eventually, when Googlebot fails, the site suffers.
Introduction
When we talk about Search Engine Optimization, React websites face huge challenges. One major reason is that most React JS developers and development companies focus more on the client-side rendering, whereas Google focuses on server-side rendering. This creates tremendous challenges for ReactJS & SEO both.
On this note, we are going to talk about the basics of React SEO. This guide lists the challenges that restrict React from being SEO-friendly. Alongside, we will even see the best practices that enable your application to rank better and higher in Google search results.
How SEO Works?
Of all online searches, Google receives around 90% of it when it comes to SEO. Before delving into how SEO works, let’s look into the crawling and indexing process of Google.
Points to Remember:
Googlebot keeps up with a crawl queue having all the URLs it requires to crawl and index henceforth.
When the crawler stays unoccupied, it picks up the upcoming URL in the queue, requests, and collects the HTML.
Subsequently, Googlebot decides it is required to collect and execute JavaScript after parsing HTML. In case it does, the URL gets added to a render queue.
In the latter point, the renderer collects and executes JavaScript to render the page, thereby sending the rendered HTML back in its position.
The processing unit takes out all the URL tags mentioned on the web page and adds them to the crawl queue back.
The content gets added to Google’s Index.
Did you notice the clear difference between the Rendering stage executing JavaScript and the Processing stage parsing HTML? Well, this differentiation takes place based on cost. Executing JavaScript is costly as it needs to have a look at 130 trillion Webpages.
Quick Read:Top Reasons to Choose ReactJS for Web Development in 2021
General SEO Challenges
Below are a few SEO Challenges that software engineers and developers can address and fix.
1. Empty First pass content
It is known that React applications depend on JavaScript. As a result, they struggle with Search engines. This happens due to the app shell model employed by React. Initially, HTML does not include any meaningful content, which is why a bot or a user needs to execute JavaScript to view the page’s actual content. This approach denotes that Googlebot traces a void page during the initial pass. Thus, the content is viewed by Google only while the page gets rendered. Eventually, this leads to a delay in indexing within thousands of pages.
2. Page Metadata
Meta tags are brilliant because they enable social media websites and Google to display valid thumbnails, titles, and descriptions for a particular page. But, these websites depend on the tag of the collected webpage to obtain this information. This site does not perform JavaScript for the landing page. React renders every content, even the Meta tags. As the app shell remains the same for the app/website, it becomes difficult for individual pages to adapt the metadata.
3. Sitemap
A sitemap is a file where all details about your site’s videos, pages, and other forks are provided, along with the relationship between them. Being an intelligent search engine, Google reads this file to crawl into your site easily. React does not possess any inbuilt method to create sitemaps. If you use React Router to manage to route, you need to find tools to create a sitemap. Although, this might require some of your efforts.
4. User Experience and Loading Time
No matter what the task is, Fetching, executing, and parsing JavaScript takes immense time. Furthermore, JavaScript may even require making network calls to collect the content while the user must wait for a while to view the requested details. In terms of ranking criteria, Google has flourished a set of web vitals regarding user experience. Extended loading times affect the user experience score, thus informing Google to rank the site lower.
5. Other SEO Considerations
Below is a few considerations that are linked to setting up excellent SEO practices.
Use a CDN to serve each static asset such as JS, CSS, Fonts, etc., and use responsive images to lower the loading times.
Improving the robots.txt file can assist search bots in analyzing how to crawl on your website.
If you want to improve your React application performance, then React.memo is a great solution to achieve the same!
Read More: React SEO Challenges
0 notes