Question presented to candidate: "In one or two sentences, what is Node.js, and what specifically made it popular compared to earlier server-side technologies?"
What a strong answer should cover:
- Node.js is a JavaScript runtime built on Google's V8 engine (the same engine that powers Chrome), extended with APIs for file system access, networking, and other system-level operations that a browser deliberately does not expose.
- Its defining architectural choice is a single-threaded, event-driven, non-blocking I/O model — instead of spawning a new OS thread per connection (the traditional Apache/thread-per-request model), Node handles many concurrent connections on one thread by never blocking that thread on I/O.
- This made it genuinely well-suited to I/O-heavy, high-concurrency workloads (APIs, real-time apps, proxies/gateways) — it does not make CPU-bound work faster, and a good answer names that boundary rather than claiming Node is universally fast.
- A major, historically significant factor in its popularity beyond the technical model: using one language (JavaScript) on both the frontend and backend removed a real context-switching cost for teams and enabled code/tooling sharing (validation logic, types, occasionally whole modules) across the stack.
- npm, bundled with Node, gave it the largest package ecosystem of any language runtime at the time — a genuinely practical adoption driver alongside the technical architecture.
- A precise answer distinguishes "Node.js is a runtime" from "Node.js is a framework" — Express, Fastify, NestJS, etc. are frameworks built on top of Node, not Node itself.
Clarifying questions expected:
- "Is the comparison against a specific alternative (Python/Django, Java/Spring, PHP), or general?" — the strongest specific comparisons are I/O-concurrency-model-based, not just "Node is faster."
- "Is the interviewer asking about the runtime itself or the ecosystem (npm, frameworks) around it?" — these are commonly conflated.
Code / implementation expected: Optional — this is a definitional question; a short snippet showing the non-blocking model in action is a nice addition, not a requirement.