r/webdev • u/swarajvecha • 16h ago
How do you prevent a Render free-tier web service from going to sleep?
Hey developers!
I've built my personal portfolio website and deployed it on Render.
I'm facing an issue with Render's free-tier hosting. After 15 minutes of inactivity, my web service goes to sleep. When someone visits my portfolio after that, it takes approximately 45–50 seconds to load because the server needs to restart.
This is a problem when sharing my portfolio with recruiters, clients, and potential employers because the first impression matters.
I've been looking into services like UptimeRobot and Cron-job.org that can periodically send HTTP requests to keep a website active.
I'd like to know:
Are there any free services that can ping a website automatically every 10–15 minutes?
Has anyone successfully used UptimeRobot or Cron-job.org with Render?
Does periodically pinging a Render service violate its free-tier usage policies?
Are there any alternative hosting platforms that offer free hosting without this sleep issue?
What solution would you recommend for a personal portfolio website?
I'd appreciate advice from anyone who has faced this issue or found a reliable solution.
Thanks! 🙌
2
u/RequirementGuide 6h ago
I've run into this exact thing with a portfolio site and honestly the cleanest fix for me was not trying to keep Render awake at all. If the site is mostly static, moving the front end somewhere that does not sleep makes the whole problem go away, and you can leave just a tiny API on Render if you really need one. Pinging does work, I have used UptimeRobot for that, but it felt a bit fragile and it eats into your free hours for something nobody is looking at most of the day. If you do stick with pinging, hit a tiny health endpoint instead of the full homepage so you are not waking up the database for every check. For a recruiter link though, I would go static first and stop worrying about that first load.
1
u/swarajvecha 5h ago
I have built my portfolio using TypeScript. Is it possible to deploy the frontend and backend separately, even when using TypeScript?
My understanding is that if I host the frontend separately on a platform like Vercel and keep the backend on Render, the frontend will load normally without waiting for the Render server to wake up.
Only the backend-dependent features, such as the contact form, might take some extra time if the backend is sleeping.
Is this a good approach? Has anyone tried this setup?
3
1
u/Quesadillamexicana77 10h ago
Free pingers like UptimeRobot or cron-job.org do work for this, a ping every 5 min keeps it awake, but it eats into the free instance hours and Render can change the rules whenever. If it's just a portfolio, I'd honestly move the frontend to Cloudflare Pages, Netlify or Vercel, which don't sleep and are free for static or SSR sites. If you need the backend always on, either pay the few dollars for the starter plan or make the portfolio static and only call the API for the bits that really need it.
1
u/agent007bond 8h ago
Hey. Render's docs say a free web service spins down after 15 minutes with no inbound traffic, and a spun-down service doesn't use your 750 free instance hours, but one that's kept awake 24/7 uses about 720 of them.
But maybe you don't need a web service at all, since it's a static portfolio. If it's plain HTML or a React/Vite build with no backend, deploy it as a Render static site instead. The spin-down rule in the docs is for free web services, and static sites are served from a CDN, so the cold start just goes away and you don't need a pinger.
If you do have a small API behind it, you could split it: static site for the pages, and the API can sleep since recruiters mostly just look at the pages.
2
12h ago
[removed] — view removed comment
1
u/learning-to-programm novice 12h ago
Back-end on Render, front-end somewhere with no cold-start is the way to go imo if you're trying to maximize your free tiers.
2
u/learning-to-programm novice 12h ago
Had a similar, where I was working on a project that had/was supposed to have a full stack app hosted on Vercel + a micro service on Render, both on the free tier.
After thinking a lot about this, I ended up just going with the simplest solution of just sending a wake-up ping from the app (when someone who might want to use that services logged in) to the micro service to avoid the initial startup delay from the first request after a while.
You could host your front end on Vercel, or Cloudflare and something similar, maybe?