ANS Documentation

Improve This Doc
  • Cloud
  • Domains and DNS management
  • Backup and High Availability
  • eCommerce Stacks
    • Magento
      • Magento 1
      • Magento 2
    • Shopware
    • WooCommerce
    • AeroCommerce
  • Security
  • Email
  • Monitoring and usage management
  • Networking
  • Operating systems
  • Webcelerator
  • MyUKFast
  • Home >
  • eCommerce Stacks >
  • Magento >
  • Magento 1 >
  • Time To First Byte (TTFB)

Time To First Byte (TTFB)¶

Time To First Byte (TTFB) is a measurement to show the responsiveness of your Magento website. TTFB measures the time from the end user making an HTTP request to the first byte of the page being received by the end user’s browser. Magento can show a slower TTFB as it does not send any bytes until PHP has rendered the whole page (Unless there are cache mechanism in place).

Server Time To First Byte¶

You can test the response time of the server with a simple PHP info page. This will show you the speed of which the network, server, web service and PHP-FPM response:

 ~]$ curl -o /dev/null -s -w "Time: %{time_total} \n" https://exampledomain.com/info.php
Time: 0.197

Magento Time To First Byte¶

Comparing the same test when accessing Magento will provide an indication of server response time versus Magento response time:

 ~]$ curl -o /dev/null -s -w "Time: %{time_total} \n" https://exampledomain.com/index.php
Time: 2.034

The key to having a lower TTFB with Magento is to optimise Magento to reduce the load time. Some recommendations on improving TTFB:

  • Implement Full Page Cache (ideally with Varnish)

  • Memory based session management (Redis)

  • Disable/Remove unused modules in Magento

  • Optimise code in theme .phtml files

  • Ensure Magento is on the latest version

  • Optimise static content (reduce image sizes, minify .js & .css files)

Next Article > Database Triggers

  • Useful Links
  • SMB
  • Enterprise
  • Channel
  • Public Sector
  • ANS Data Centres
  • About ANS
  • Careers
  • Blog
  • Get in touch
  •  
  • Sales 0800 458 4545
  • Support 0800 230 0032
  • Get in touch

© ANS Group Limited | Terms and Conditions | Corporate Guidance | Sitemap
ANS Group Limited, registered in England and Wales, company registration number 03176761, registered office 1 Archway, Birley Fields, Manchester M15 5QJ