Magento2 – How to Fix Error 503 First Byte Timeout During Customer Login

fastlymagento2magento2-cloudvarnish

I'm facing a cache issue that wasn't there before, my Adobe Commerce Cloud 2.4.5 + Fastly is showing this error message below when I'm trying to log in via customer account or perform some actions in the admin panel.

Magento 2 Cloud Error 503 first byte timeout

How could I solve it?

Best Answer

It's caused by Fastly limits. Try to increase your memory_limit and max_execution_time in your php.ini and pub/.user.ini files.

Then run the command composer update fastly/magento2, to make sure you have the latest version of it. To complete the limits increasing, navigate to admin -> stores -> configuration -> Advance -> System -> Full Page Cache, set Admin path timeout to 600, and click on "Upload VCL to Fastly", this will increase the first-byte timeout in Fastly (600 is the max).

Magento 2 - Fastly Admin path timeout to 600

Related Topic