# How to set default project on startup node-red?

**URL:** <https://discourse.nodered.org/t/how-to-set-default-project-on-startup-node-red/69012>\
**Category:** General\
**Created:** [14 October 2022 06:48 UTC](https://discourse.nodered.org/t/how-to-set-default-project-on-startup-node-red/69012 "2022-10-14T06:48:15Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![gimapei](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gimapei/32/49000_2.png) [@gimapei](https://discourse.nodered.org/u/gimapei)\
**Post date:** [14 October 2022 06:48 UTC](https://discourse.nodered.org/t/how-to-set-default-project-on-startup-node-red/69012/1 "2022-10-14T06:48:15Z")

</div>

hello guys.  
Can I know how to set the default project on startup node-red.  
when I use multiple projects on node-red.  
and it is managed by pm2.

when I startup node-red from pm2, it always connected the first project.  
I want each project to be mapped to each node-red process.

Can I set the configuration file for this?

Thanks.

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [14 October 2022 16:37 UTC](https://discourse.nodered.org/t/how-to-set-default-project-on-startup-node-red/69012/2 "2022-10-14T16:37:27Z")

</div>

I don't know of a direct way. I think that the active project is defined in the file `~/.node-red/.config.projects.json`.

So each of the instances you want to start up will need a different file. Assuming you only want to ever run a single instance of node-red at a time, your PM2 startup script will need to copy the correct version of the file to the live file name.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [13 December 2022 16:38 UTC](https://discourse.nodered.org/t/how-to-set-default-project-on-startup-node-red/69012/3 "2022-12-13T16:38:21Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
