Debugging nodeJS in node-inspector



I am trying to debug my server side Node JS code in Cloud9. I’m following the steps here:

I run into a problem when I try to connect to in my web browser. It connects my computer’s localhost instead of the Cloud9 localhost.

How can I launch a website inside Cloud9 to connect to localhost?


localhost = your computer

You have to find the URL of your workspace and use it. Please read this.


I made some progress but not fully solved.

In my Procfile I put:
web: node --debug=8082 app.js

My log showed:
Debugger listening on port 8082

I started node-inspector in bash with:
node-inspector --web-port=$PORT --web-host=$IP --debug-port=8082

I was able to load the node-inspector interface at when I went to the following address in Chrome:

But nothing appeared in the node-inspector. There were no sources. Any ideas? After a few seconds, the node-inspector windows give the error:
Detached from the target. Reason: websocket_closed


Hey, did you find an answer to this?


I never fully got it working. I think I was pretty close with my last message above. Please share if you solve it.


I am having this same problem.
My node application server is hogging $IP and $PORT because that’s what C9 wants.
The app is sicko, and needs a deep inspection. The debugger needs a second port because 8080 is taken.

How can I either use the internal debugger, or open a port or whatever node-inspector needs?