---
title: "How do I specify the root directory or output directory for my Node.js project?"
date: "2025-05-26T13:32:16+00:00"
summary: "Learn how to set root and output directories for Node.js projects using package.json configurations. Optimize your project structure."
image:
type: "article"
url: "/acquia-cloud-platform/add-ons/code-studio/help/69261-how-do-i-specify-root-directory-or-output-directory-my-nodejs-project"
id: "17d758db-cdf2-4dda-8942-cb2cd42ce23e"
---

*   To specify the root directory, add the directory path to the `extra.acquia.root_directory` section in the `package.json` file of the root directory.
*   To specify the output directory, add the directory path to the `extra.acquia.output_directory` section in the `package.json` file of the root directory. For example:

    "extra": {       
                 "acquia": {
                   "root_directory": "front-end/",
                   "output_directory": "assets/"
                 }
                }

The default root directory is `<project_root>/`, and the default output directory is `<project_root>/.next/`.