Is it possible on the server dynamic PHP and JS pages to keep static?

What do you think, is it possible to use this type of acceleration, open dynamic pages?
There are nginx, php, mysql, JavaScript.
In the browser otkryvaete that stuff is not very quickly to 5-10 seconds.
Is it possible in any way to save room and open in the browser as a static page, and then reuse them in, say, nginx as a static site?
Maybe there are utilities to do this? Or something homemade, like to periodically run a selenium script, which the browser will store pages in a directory with nginx. And he will have to open them as static.

Reviewed a bunch of generators from this page: https://www.staticgen.com/
But it's not quite the same, because they do not know how to work with php pages that get data from DB.
June 5th 19 at 21:32
3 answers
June 5th 19 at 21:34
Solution
Cache in nginx is
Cache in php do not the problem

Static websites and their generators not being here at all.
Helped the so-called Microcaching with Nginx.
https://www.nginx.com/blog/benefits-of-microcachin...

And exactly these settings:
fastcgi_cache
fastcgi_cache_lock on;
proxy_cache_use_stale updating; - Marcia_OKon commented on June 5th 19 at 21:37
this is normal klirovaniya in nginx, for effect, called micro for some reason) - bailee_Stant commented on June 5th 19 at 21:40
June 5th 19 at 21:36
In the browser otkryvaete that stuff is not very quickly to 5-10 seconds.

with SQL, all right ?
if Yes, then you need to look into the caching, for example https://www.phpfastcache.com/
June 5th 19 at 21:38
Determine first the reason for the slow return of data from the server,

1) the network is not really that unlikely
2) the problem in the code
- recursion, loops, and other
- slow queries in sql, possibly not a true organization of the data, whether there are indexes, how is the sample
if you work with files, you can to eat a lot of CPU time
- pictures are not generated on the body? vatermarki and other

Find more questions by tags NginxCaching