Skip to main content
Table of contents

Install with Node.js package manager (npm)


  1. Install Node.js.

    If you have not already installed version 4.2.0 or later of Node.js, install the latest Long Term Support (LTS) version.

  2. cd to the root of your project and check if you have a package.json file. If you do not have the file, create it by running:

    npm init
  3. Install Dart Sass - version 1.0.0 or higher.

    GOV.UK Frontend also works with:

  • LibSass - version 3.3.0 or higher
  • Ruby Sass - version 3.4.0 or higher

    However, we recommend you do not use either LibSass or Ruby Sass, as they’ve been deprecated.

You can also install Nunjucks v3.0.0 or later if you want to use GOV.UK Frontend’s Nunjucks macros.

Install GOV.UK Frontend


npm install govuk-frontend --save

When the installation finishes, the govuk-frontend package will be in your node_modules folder.

You should now get started by getting the CSS, assets and JavaScript working with one GOV.UK Frontend component.