Blogging Other Websites WordPress


What is the time for the first byte (TTFB)?

When someone selects your website on Google, their web browser requests information – or bytes – from a server. TTFB is the number of milliseconds it takes for a browser to receive the first byte of a response from your web server.

Time spent waiting for initial response, also known as time to first byte. This time captures the latency of a round trip to the server in addition to the time spent waiting for the server to respond.

A website with a high TTFB may disappoint its visitors. If your web server page takes too long to send the first byte of the request, two problems may occur:

Visitors to your website will leave your site and instead visit your competitor’s site
Your website’s SERP rank may suffer because Google takes the TTFB into account

What Causes Slower TTFB?

Four causes of slow TTFB are:

  1. High web traffic
  2. Network problems
  3. Dynamic content:
    • disk usage
    • disk speed
    • RAM usage
    • database setup
    • database speed
  4. Server configuration:
    • PHP/ASP settings
    • database settings
    • shared server?
    • etc.

6 ways to improve TTFB:


1. Use a Content Delivery Network

A Content Delivery Network (CDN) is a geographically distributed network of servers that allows users to download data from websites they are visiting using the nearest network node. This way the website will be faster in both download and page load and the user experience will improve. The use of a CDN is not required for all types of websites, so it is useful to understand if there is any point in using that service.


2. Optimize Application Code

Application code is an important part in website optimization. Several actions help speed up TTFB as application code: reverse proxy to add load balancer and cache static and dynamic content, update software installed on web servers, speed up applications and secure them Use the server. In addition, compress data and implement HTTP / 2, as well as monitor web server performance and live activities to identify potential bottlenecks.


3. Optimization of database queries

To optimize a database query you first need to build the index properly and retrieve only the data that you really need. Also, avoid using the operator’s left-hand functions, so you don’t have to read the entire database to answer the query. Also avoid correlated sub-categories, as they depend on other queries and slow down the process.


4. Reduce HTTP Requests

To reduce HTTP requests you need to check how many requests your website currently makes and remove unnecessary images. Once you create it, you can reduce the file size of the remaining images and analyze which factors can affect the load speed. Other things you can do to optimize TTFB are make JavaScript asynchronous and combine CSS files together.


5. Ensure a faster server response time

Here too it is important to intervene on CSS and JavaScript files and combine outsiders. In some cases you can use small inline CSS and JavaScript files, putting them in an HTML file, so you won’t need external resources and no additional calls to them. It is also an important deforming diagram, as it helps to save bandwidth and reduce page load time.


6. Use Response First, Process After (RFPL) cache

With this cache method the user quickly sees the previously cached response and at the same time, the server still processes the request in the background. In this way users are not awaited feedback.

The conclusion

When improving TTFB, there are several details to consider. Those who follow measures to improve their TTFB and enjoy competitive advantage. Like SEO and other labor intensive website initiatives that give consumers a better experience, it is all worth it at the end of the day.

Leave a Reply