cancel
Showing results for 
Search instead for 
Did you mean: 

Problem time the first byte (TTFB)

Problem time the first byte (TTFB)

Hello,

 

I have a problem with time the first byte (TTFB).

I have a Debian server with Plesk Nginx and Magento 1.9.1.0

I have the full page cache Module Mirasvit and use redis for backend

 

Here are my results for the home page of my website:
Load Time: 2.060 s
First Byte: 0.312 s
Start Render: 1303 s
Note in webpagetest.org: F A A B A X (First Byte Time - Keep-alive Enabled - Compress Transfer - Compress Images - Cache static content - Effective use of CDN)

 

Here are my results for a blank html file on my website:
Load Time: 0.160 s
First Byte: 0.101 s
Start Render: 0.000 s
Note in webpagetest.org: A A A N/A X (First Byte Time - Keep-alive Enabled - Compress Transfer - Compress Images - Cache static content - Effective use of CDN)

 

One of my conccurents it (without CDN):
Load Time: 3.838s
First Byte: 0.123s
Start Render: 0.697s
Why ? :-( I do not understand

 

In PageSpeed ​​Insights problem I like: Reduce the response time of the server.

 

This does not come from the host because he has a very good reputation.
I changed many parameters in the server but still the same result (nginx, opcache ...)

My website is www.creatissim.com

 

I can not detect which way the TTFB problem? server? magento even if the site load 2 sec?

If you have ideas or a test to isolate the problem ...

 

Thank you for your replies :-)

4 REPLIES

Re: Problem time the first byte (TTFB)

Your time to first byte is still .5 seconds but your content is taking 4.5 seconds to download.  (Which is primarily CSS and JS) 

 

First you need to combine all those files using the merge feature in Magento. 

Your repeat view on your Time to first byte doesn't go up much so I would guess you server is slow.

 

You have some very large images that load after 3.0 seconds.

 

 

Magento Moderator since 2009
Keep Calm and Clear Cache!

Re: Problem time the first byte (TTFB)

You could try enabling the Magento Varien Profiler which once the page loads will tell you what within the index.php code was taking the longest to run and thus causing the long TTFB. It can also tell you if it is a database connection/query that is doing it.

 

Inchoo wrote a great guide on how to do this here:

http://inchoo.net/magento/keeping-your-magento-fit-with-built-in-profiler/

Re: Problem time the first byte (TTFB)

Aoe Profiler is a fantastic tool which will help you by providing insights on objects and queries.

 

https://github.com/AOEpeople/Aoe_Profiler

 

Also you can refer some of the guidelines listed here in 

 

http://aionhill.com/8-effective-ways-to-really-boost-magento-page-speed/

 

Re: Problem time the first byte (TTFB)

you need to enable Magento Profiler and audit its output. Inspect calls with most times and study php code to identify a problem if any.

 

Here is a detailed guide on how to optimize TTFB.

 

I checked your website in Google Page Speed Insights and the only problem you have is with render-blocking Javascript and CSS.

 

Google Page Speed Insights

 

that could be fixed with defer loading of javascript implementation.

Add async tag to your external javascript scripts and load inline javascript script right after a browser is done with executing external scripts.

<script type="text/javasript" src="..." async></script>