Appendix A. Installing Node
This appendix provides more details on installing Node.js. If you’re fairly new to Node, we recommend installing it with a prebuilt package. We explain this for each major operating system.
Depending on your requirements, you can install Node in other ways instead. If you’re more experienced with Node or have specific DevOps requirements, skip ahead to review other ways you can install Node.
Node has two installers and several prebuilt binary packages. If you use macOS or Windows, you can use either binaries or installers. The binary packages contain executable files, but the installers have installation wizards that help you put Node on your system in a place that’s easy to find when you’re running commands such as node or npm in the terminal.
If you’re new to Node, use an installer. All of the versions can be found on Node’s website under Downloads (https://nodejs.org/en/download/).
For macOS, download the 64-bit .pkg file from Node’s website (https://nodejs.org/en/download/). You can use either the LTS or Current release. You should see a package file, as shown in figure A.1.
After you’ve downloaded the installer, double-click it to open the installation wizard (Figure A.2).