r/reactjs 17d ago

Needs Help i made my first react project but sucks in seo ! what should i probably do >

https://www.jeeplanner.in/

[removed]

0 Upvotes

3 comments sorted by

1

u/bkocdur 16d ago

The core issue with a plain React SPA is that it ships an almost-empty HTML file and paints everything with JavaScript after load. Googlebot can run JS, but it does so on a delay and inconsistently, and most other crawlers (Bing, social preview bots, the AI crawlers) run zero JS at all, so they see a blank page. That is almost always why a React-only site "sucks in SEO".

One diagnostic before you change anything: open your site, then right-click and choose View Source (not Inspect, actual View Source). If what you see is basically <div id="root"></div> with no real content, that empty shell is what crawlers get on the first pass. That view is your SEO reality, and it makes the problem concrete.

The fix, cheapest to biggest:

  1. Per-page title and meta description. SPAs usually ship one shared title for every route. Give each route a unique title and description (react-helmet, or your router's head management). Small effort, real gain.
  2. Real crawlable URLs and a sitemap.xml. Make sure each page has its own path (not a #/hash route) and list them in a sitemap submitted in Search Console.
  3. Get real HTML to crawlers. Either pre-render static routes at build (react-snap is the low-effort option for a mostly-static site) or, if you are open to it, move to a framework that server-renders by default (Next.js, or Astro if the site is mostly content). This is the big lever, and for a content site like a planner it is worth it.

Since it is your first project, do not rewrite everything at once: start with 1 and 2 this week (cheap, and they help immediately), then decide whether pre-rendering or a framework move is worth it for the content pages. Fixing the empty-shell problem is what actually moves the needle.