When opening the website for the first time, it's quite slow — it takes around 2 to 3 seconds. But after the first load, all pages open instantly. I'm not sure why this happens.
My website consists mostly of static pages, and even when I set the PHP version to serve fully static content, there's no noticeable improvement. I'm currently using Nginx + PHP 7.4 + MySQL. To improve website speed, I use scheduled tasks in aaPannel (BaoTa) to generate static pages regularly. Interestingly, accessing the BT Panel is very fast, but opening the website itself remains slow.
Although most pages are static, some parts of the site do use PHP and connect to MySQL. I’ve also enabled the free version of the firewall.
The website is www.dkly.top. Below is a screenshot I got from a webmaster tool — it shows that the server response time is very short, but the actual load time is still relatively long. I honestly don’t know where the bottleneck is. I remember BT Panel being much faster in the past.
May I know if you have any suggestions on optimizing my Nginx and PHP settings? I’d really appreciate any recommendations for improving initial page load speed, especially considering that the site does involve PHP, MySQL, and not everything is purely static.