Learn how to deploy your Node.js Express app on Render in under 5 minutes. Includes step-by-step instructions, code examples, and troubleshooting tips.
Deploying your Node.js application doesn't have to be complicated. Render offers a free, modern platform to host your Node.js apps with automatic deployments from Git. In this guide, you'll learn how to deploy a basic Node.js Express app on Render—from setup to live URL.
Why Render?
Render is a modern cloud platform that provides:
Free tier for web services
Automatic deployments from Git
Built-in HTTPS
No configuration files needed for basic Node.js apps
Start by creating a simple Express server. Create a new folder and run:
mkdir my-node-app
cd my-node-app
npm init -y
npm install express
Create index.js:
const express = require('express');
const app = express();
const port = process.env.PORT || 3000;
app.get('/', (req, res) => {
res.send('Hello from Render! 🚀');
});
app.listen(port, () => {
console.log(`Server running on port ${port}`);
});
Update package.json:
{
"name": "my-node-app",
"version": "1.0.0",
"main": "index.js",
"scripts": {
"start": "node index.js"
},
"dependencies": {
"express": "^4.18.2"
}
}
Initialize Git and push your code:
git init
git add .
git commit -m "Initial commit"
git branch -M main
git remote add origin https://github.com/your-username/your-repo.git
git push -u origin main
Go to render.com and sign up
Click New → Web Service
Connect your GitHub repository
Fill in the details:
Name: my-node-app
Build Command: npm install
Start Command: npm start
Environment: Node 18
Click Create Web Service
Your app will automatically deploy. Once complete, Render provides a live URL like https://my-node-app.onrender.com.
If your app uses environment variables (like database URLs or API keys):
Go to your service dashboard on Render
Click Environment tab
Add key-value pairs (e.g., NODE_ENV=production)
| Issue | Solution |
|---|---|
| App crashes on start | Verify start script in package.json |
| Port not recognized | Use process.env.PORT in your code |
| Dependencies fail to build | Ensure all packages are in package.json |
Your Node.js app is now live on Render. The platform handles SSL, scaling, and continuous deployment from your Git repository automatically.
Ready to try? Push your code and deploy in under 5 minutes!
Render offers free options for some projects, which makes it a popular choice for testing and small beginner apps.
What's next?
Apply your knowledge with one of our rigorous, hands-on internship programs.
Browse Internships