I thought setTimeout was still blocking... Javascript isn't threaded, after all. When you do a setTimeout with a large interval, doesn't it simply keep track of how long it's been since you made the call, and at the appropriate time blocks the current code and runs the function? If so, what difference does using setImmediate/setTimeout(x, 0) make?