Next.js Discord

Discord Forum

How frequently should I "revalidate" ISR page?

Answered
neon posted this in #help-forum
Open in Discord
I wanna learn what exactly does revalidate do in nextjs. Does it completely recompile the page (i.e. generateStaticParams) or only update the cached data?

More importantly, I wanna know what would be the best value for export const revalidate for me? I have a e-commerce website with about 100 products (the page /product/[slug] is statically generated using generateStaticParams). So how frequently can I afford to revalildate the page till it gets too frequent?
Answered by Anay-208 | Ping in replies
From what I know, revalidate updates the data which needs to be updated, and doesn't recompile the entire page.

generateStaticParams is not even needed, since it can also be done at the time of request
View full answer

11 Replies

bump
.
Are you using static build?
bump cause still not answered... (im starting to think my question is stupid)
Wuchang bream
revalidate how often you want and need
Answer
@Anay-208 | Ping in replies From what I know, revalidate updates the data which needs to be updated, and doesn't recompile the entire page. generateStaticParams is not even needed, since it can also be done at the time of request
Ah, okay! Just to make sure, it has no effect on SEO right? Like I won't get bad performance from robots if i revalidate too often right?
@neon Ah, okay! Just to make sure, it has no effect on SEO right? Like I won't get bad performance from robots if i revalidate too often right?
As long as your database is fast, it won’t have might affect on SEO.

Setting a perfect re validation depends upon your use case, like how often stuff is updated
Thank you so much!