How does Suspense on server components affect SEO?
Unanswered
Satin Angora posted this in #help-forum
Satin AngoraOP
Assume I'm building an e-commerce platform and the user lands on a product page.
Right now, everything is loaded via an API/Suspense, so we get a quick render of the page with Skeletons to show that the data is loading, and then once the data is ready, it'll be displayed.
I am just wondering what the SEO consequences of that are, and whether I should be leveraging some sort of techniques to not have this happen? I am dealing with a site with 20,000+ products, so static rendering seems like a no go, specially because a lot of them will have constant updates/changes.
Just checking how you guys tackle stuff like this
Right now, everything is loaded via an API/Suspense, so we get a quick render of the page with Skeletons to show that the data is loading, and then once the data is ready, it'll be displayed.
I am just wondering what the SEO consequences of that are, and whether I should be leveraging some sort of techniques to not have this happen? I am dealing with a site with 20,000+ products, so static rendering seems like a no go, specially because a lot of them will have constant updates/changes.
Just checking how you guys tackle stuff like this
15 Replies
Siberian
This and the linked article might be of help https://www.reddit.com/r/nextjs/comments/wmk6gv/impact_of_react_suspense_used_with_nextjs_on_seo/
as well as
https://github.com/vercel/next.js/discussions/50829
as well as
https://github.com/vercel/next.js/discussions/50829
but as for ISR not being viable for you, I'm assuming you mention this because of the build time you expect? Cause you don't have to prerender all pages on build. You could just prerender a slight subset of them at build time, let the rest be rendered upon first visit and then cached
obviously you will have to properly handle revalidating but might be worth while for your usecase
Satin AngoraOP
Interesting. Will do a deeper deep-dive then. Feels like there's really no straight answer which I guess is to be expected with something like SEO as the guidelines aren't really super clear.
re: prerendering, you're right maybe it isn't such a big deal. Will also do some more research I guess.
This all seems kind of scary because although I understand the benefits of what NextJS is offering, our current "dumbed down" setup with just Django/HTML & some React mounting on few components is doing really really great on SEO, so wouldn't want to hurt that
re: prerendering, you're right maybe it isn't such a big deal. Will also do some more research I guess.
This all seems kind of scary because although I understand the benefits of what NextJS is offering, our current "dumbed down" setup with just Django/HTML & some React mounting on few components is doing really really great on SEO, so wouldn't want to hurt that
Siberian
ha yeah SEO is scary in that way
always feels like such a black box
Satin AngoraOP
Another quesiton, is it an extremely dumb idea to have an api that returns all the products in my database but just their name + description, and have that kind of preloaded/cached always, that way on navigating to a product page, i can at least load in some metadata + h1 tags from that data and then wait for APIs to get the full data and load the rest of the page?
Siberian
would you have that cache client side or server side?
if server side, this is somewhat what partial prerendering is
Chausie
SEO will be dead anyways in a year or so, it's not 2010 anymore.
Siberian
you can have some part of your page cached while still having dynamic server components that rerender on each request
but to be honest I think for something like a webshop ISR really is great
@Chausie SEO will be dead anyways in a year or so, it's not 2010 anymore.
could you elaborate more on this? mainly for e-commerce
@Satin Angora Assume I'm building an e-commerce platform and the user lands on a product page.
Right now, everything is loaded via an API/Suspense, so we get a quick render of the page with Skeletons to show that the data is loading, and then once the data is ready, it'll be displayed.
I am just wondering what the SEO consequences of that are, and whether I should be leveraging some sort of techniques to not have this happen? I am dealing with a site with 20,000+ products, so static rendering seems like a no go, specially because a lot of them will have constant updates/changes.
Just checking how you guys tackle stuff like this
As far as I know, Next.js doesn’t send Suspense when it detects bots and crawlers, so it’s still SEO friendly.
Though I’m not 100% sure. Best to still check on the Google Search Console to what the Google bot can see in your site.
Though I’m not 100% sure. Best to still check on the Google Search Console to what the Google bot can see in your site.
@TiagoMunder could you elaborate more on this? mainly for e-commerce
Chausie
The future is paid promotion only, Google will spit out promoted AI generates suggestions no need anymore for google to crawl all websites, they will crawl the ones who pay.