jamwalsudip/playwright-mcp-server
If you are the rightful owner of playwright-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to dayong@mcphub.com.
The Playwright MCP Server for Render is a cloud-based solution for browser automation, designed to work seamlessly with n8n workflows and other MCP clients.
Playwright MCP Server for Render
This repository contains a ready-to-deploy Playwright MCP (Model Context Protocol) server configured for Render cloud hosting. It enables browser automation capabilities accessible via n8n workflows or any MCP client.
What This Does
- Runs a Playwright MCP server in the cloud (24/7)
- Provides 21+ browser automation tools
- Accessible via HTTP for n8n integration
- Completely independent of any local machine
Quick Deploy to Render
Prerequisites
- A GitHub account
- A Render account (free tier available at render.com)
Deployment Steps
Step 1: Push This Repository to GitHub
-
Create a new repository on GitHub:
- Go to github.com/new
- Name it:
playwright-mcp-server - Make it Public or Private (your choice)
- Do NOT initialize with README (we already have one)
- Click "Create repository"
-
Push this code to GitHub:
# Navigate to this directory cd playwright-mcp-render # Initialize git git init # Add all files git add . # Commit git commit -m "Initial commit: Playwright MCP server for Render" # Add your GitHub repository as remote git remote add origin https://github.com/YOUR-USERNAME/playwright-mcp-server.git # Push to GitHub git push -u origin main
Step 2: Deploy to Render
-
Go to dashboard.render.com
-
Click "New +" → "Web Service"
-
Connect your GitHub repository:
- Click "Connect account" if not already connected
- Find and select
playwright-mcp-server - Click "Connect"
-
Configure the service:
- Name:
playwright-mcp-server(or your preferred name) - Region: Choose closest to you
- Branch:
main - Runtime:
Node - Build Command:
npm install && npx playwright install --with-deps chromium - Start Command:
npm start - Plan:
Free
- Name:
-
Click "Create Web Service"
-
Wait for deployment (5-10 minutes)
- Render will install dependencies
- Install Playwright browsers
- Start the server
- You'll see logs in real-time
-
Get your endpoint URL:
- Once deployed, you'll see a URL like:
https://playwright-mcp-server.onrender.com - Your MCP endpoint is:
https://playwright-mcp-server.onrender.com/mcp
- Once deployed, you'll see a URL like:
Step 3: Configure n8n
-
In your n8n workflow:
- Add an AI Agent node
- Add MCP Client Tool to the agent
-
Configure MCP Client Tool:
- Endpoint:
https://playwright-mcp-server.onrender.com/mcp - Server Transport:
HTTP Streamable - Authentication:
None - Tools to Include:
All
- Endpoint:
-
Test the connection by running your workflow
Important Notes About Render Free Tier
Limitations
-
Spins down after 15 minutes of inactivity
- First request after spin-down takes ~30 seconds to wake up
- Subsequent requests are fast
-
512 MB RAM
- Sufficient for most browser automation tasks
- May struggle with very complex pages or multiple simultaneous requests
-
750 hours/month free
- More than enough for testing and development
Upgrading
If you need always-on service:
- Upgrade to Starter plan ($7/month)
- Gets you 1GB RAM and no spin-down
Troubleshooting
Deployment Fails
Issue: Build fails with "Out of memory" Solution: This is rare on Render, but if it happens, try:
- Reduce browser installations to just Chromium (already configured)
- Upgrade to paid tier for more RAM
Issue: "Port already in use"
Solution: The server.js automatically uses Render's PORT environment variable. No action needed.
n8n Connection Issues
Issue: "Cannot connect to MCP server" Solution:
- Check if Render service is running (green status in dashboard)
- Verify the endpoint URL is correct
- Wait 30 seconds if service just spun down
- Check Render logs for errors
Issue: "First request is very slow" Solution: This is normal on free tier. The service spins down after 15 minutes of inactivity. First request wakes it up (~30 seconds).
Browser Automation Fails
Issue: "Browser crashed" or "Out of memory" Solution:
- Free tier has 512MB RAM, which is limited
- Try simpler automation tasks
- Upgrade to Starter plan ($7/month) for 1GB RAM
Architecture
User → n8n Workflow → MCP Client Tool → Render (Playwright MCP Server) → Browser → Results
Files in This Repository
package.json: Node.js dependenciesserver.js: Wrapper script that starts MCP server with correct configurationrender.yaml: Render deployment configuration (optional, for Blueprint deployment).gitignore: Files to exclude from GitREADME.md: This file
Environment Variables
The server automatically uses these environment variables set by Render:
PORT: Automatically set by Render (usually 10000)NODE_ENV: Set toproductionPLAYWRIGHT_BROWSERS_PATH: Cache location for browsers
No manual configuration needed!
Monitoring
Check Server Status
Visit your Render dashboard to see:
- Service status (running/sleeping)
- Recent logs
- Deployment history
- Resource usage
View Logs
In Render dashboard:
- Click on your service
- Click "Logs" tab
- See real-time server logs
Updating the Server
To update the MCP server version or configuration:
- Make changes locally
- Commit and push to GitHub:
git add . git commit -m "Update configuration" git push - Render auto-deploys (if enabled) or click "Manual Deploy" in dashboard
Cost
-
Free tier: $0/month
- 750 hours/month
- 512 MB RAM
- Spins down after 15 min inactivity
-
Starter tier: $7/month
- Always on
- 1 GB RAM
- Better for production
Security Considerations
For Production Use
Currently, the server has no authentication. For production:
- Add API key authentication
- Use HTTPS (Render provides this automatically)
- Restrict access to known IP addresses
- Monitor usage to detect abuse
Support
- Render Documentation: render.com/docs
- Playwright MCP: github.com/microsoft/playwright-mcp
- n8n Documentation: docs.n8n.io
License
MIT
Contributing
Feel free to submit issues or pull requests to improve this deployment configuration.