Skip to main content
This guide walks you through the full process of contributing — from creating a branch to opening a pull request.
Before starting, make sure you have completed installation and can run the development server locally.
1

Sync your fork

Always start from an up-to-date copy of the main branch:
git fetch upstream
git merge upstream/main
2

Create a new branch

Create a branch with a descriptive name for your change:
git checkout -b name-of-your-branch
Use a name that reflects what you are changing, for example fix/navigation-accessibility or feat/download-stats-component.
3

Make your changes

Make the changes you want to contribute. A few pointers:
  • For repository structure guidance, refer to the technologies documentation.
  • For adding new pages, follow the adding pages guide.
  • For building UI components, follow the creating components guide.
Run the development server while you work to preview changes in real time:
pnpm dev
4

Format and lint your code

Before committing, run the formatter and linter to ensure your code meets the project’s standards:
pnpm format
This single command runs Prettier, ESLint fixes, and all other formatting checks across the entire codebase.
You can also run individual checks:
  • pnpm lint — check for linting errors without fixing
  • pnpm lint:fix — attempt to automatically fix linting errors
  • pnpm prettier — check formatting only
  • pnpm prettier:fix — fix formatting issues
5

Run the tests

Run the test suite to make sure your changes do not break anything:
pnpm test
If you are adding a new feature or fixing a bug, include tests for your changes. Contributors are responsible for fixing any tests that fail.
6

Commit your changes

Stage and commit your changes. This project follows the Conventional Commits specification:
git add .
git commit -m "feat: add new component for download statistics"
Commit message rules:
  • Must include a type prefix (e.g. feat:, fix:, docs:, chore:)
  • Must be written in lowercase, except for proper nouns
  • Must not end with a period .
Commits should be signed. See GitHub’s commit signing documentation for setup instructions.
7

Push your branch

Push your branch to your fork:
git push -u origin name-of-your-branch
8

Open a pull request

  1. Go to your fork on GitHub.
  2. Click New Pull Request.
  3. Select your branch and compare it against nodejs/nodejs.org’s main branch.
  4. Fill in the pull request description, explaining what changed and why.
  5. Submit the pull request.
Pull requests must remain open for at least 48 hours (72 hours if opened on a weekend) before they can be merged. See the pull request policy for full details.

Getting help

If you get stuck at any point:

Build docs developers (and LLMs) love