SEO
In this lesson you will learn the pillars of SEO. You will lean few new terms and metrics that can help you to measure your application.
SEO stands for Search Engine Optimization and is a set of best practices to ensure that a site is well-indexed by search engines. This optimization will bring advantages in terms of traffic, and therefore, the business will also benefit significantly. This chapter will explore some best practices to ensure the application is perfectly configured for excellent SEO.
It's important to understand that search engines scan web pages to index websites and ensure that the result of a search is as accurate as possible. This scan has a limited time for each site, and therefore, the more useful information that can be provided in this short time, the better it is for the site/application. The architectures seen in the previous chapters, Server Side Generation and Server Side Rendering, can be used to provide a quality result in the shortest possible time. These two approaches guarantee the return of an HTML page containing crawlable content to the search engine crawler. So, if these technologies are used, a good start is ensured.
The fundamental aspect of obtaining a good ranking is to have interesting content or provide a useful and frequently used service. The more visitors a site receives, the more the search engine will consider it an interesting result to show. It is not only necessary that the content attracts users, but visitors must also spend time within the application.
Bounce rate#
A first metric to consider and constantly monitor is the bounce rate
because it indicates how much people appreciate or, more importantly, don't appreciate the application or the user experience.
This metric measures how many people visit a single page on the application or site and don't interact with the page before leaving.
According to Google, GA4’s engaged sessions meet at least one of the following conditions:
Lasts longer than 10 seconds
Has a conversion event
Has 2+ page views
So, for example, it measures users who leave an e-commerce site without purchasing something or interacting (e.g., clicking a link). The contents can certainly influence this metric, but it could also depend on the application's loading time, which is too slow, and therefore, the user prefers to choose one of the competitors. Fortunately, with the use of Qwik, any slowness problems can be avoided.
A high bounce rate
value means that the user's overall session duration is short. On the other hand, a low value means that they spend time on the page and interact with it.
It should be noted that a high value cannot always be considered negative; it all depends on what type of application is in use. For example, if the application provides news or other content that involves sessions from a single page, it is perfectly normal to have a high bounce rate value. If this is not the case, then this high value is a bad thing.
A bounce rate of 35% or less is good, while a bounce rate of 60% or more is high, and therefore, there is room for improvement and encouragement for users to stay more in the application.
To calculate this value, Google Analytics can be used.
Dwell time#
By measuring the time that users spend on a page before returning to the Search Engine Results Pages (SERP) we can obtain what is defined as "Dwell time". How long does the user stay on a page before moving away? This metric answers exactly this question. Let's say you are looking for how to integrate Google Maps with Qwik, and from the search results, you click on one of the first results. It's a page full of advertisements, so you go back to the SERP after only 5 seconds; the Dwell time is, therefore, 5 seconds. You click on another article, and it is well-written, pleasant to read, and very useful. You spend several minutes reading the detailed description; in this case, the Dwell time is much higher.
On the other hand, users may find the information they need at the top of the page and quickly return to the SERP, so a shorter dwell time does not necessarily indicate lower content quality or user dissatisfaction. The algorithms that calculate the ranking are not public; therefore, the best practices are the result of the experience that various experts have shared. Given the statement made earlier, Dwell time is probably not a ranking factor, at least not a direct one. However, dwell time can still provide insights into user behavior. If users tend to stay on the pages longer, it could mean they find the content engaging, and shorter stays could mean there are underlying issues causing users to bounce off the pages.