> ## Documentation Index
> Fetch the complete documentation index at: /docs/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Bach builds Windows installers from one bach.toml with the bach command: bach init, bach check, bach preview, bach build. Installs are per user and need no administrator rights by default. installer.scope = "machine" installs for every user after one Windows prompt. On Windows, run setup files with Start-Process -Wait -PassThru in PowerShell, and give signtool arguments that start with the word sign.

# Where your app is installed

> Install for one user without an administrator prompt, or for every user of a computer in Program Files. Learn about folders, defaults and permissions.

This page explains where Bach puts your app, when your users are asked for an administrator password, and how to install for everyone on a computer instead.

## The default: for the person installing

By default, Bach installs your app for the current Windows user, into:

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
%LOCALAPPDATA%\Programs\<app id>
```

For a user named Sam and an app called Hello Notes, that's `C:\Users\Sam\AppData\Local\Programs\Hello Notes`. No administrator password is needed, because the folder belongs to the user. Other people who use the same computer don't get the app; they run the setup file themselves if they want it.

Choose a different folder name with:

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[installer]
folder = "HelloNotes"
```

### Letting users choose the folder

The install window shows the location with a **Change** button. A chosen location gets your folder name added to it: if the user picks `D:\Apps`, the app goes into `D:\Apps\Hello Notes`. To always use the default location:

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[installer]
change_folder = false
```

Updates always go where the app already is.

If a first install would overwrite files that are already in the chosen folder and aren't part of your app, the window warns the user first. A silent install refuses unless it gets `--overwrite`.

## Install for every user

Some apps should be available to everyone on the computer, for example on shared office computers, or when your app includes a Windows service. Set:

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[installer]
scope = "machine"
```

Then the app goes into `%ProgramFiles%\<folder>` (usually `C:\Program Files\Hello Notes`). Before anything happens, Windows asks for permission once, or for an administrator's password on a standard account. The uninstaller asks the same way.

What changes between the two:

| | For one user (default) | For every user (`"machine"`) |
| - | - | - |
| Folder | `%LOCALAPPDATA%\Programs` | `%ProgramFiles%` |
| Entry in Settings › Apps | that user | the whole computer |
| Shortcuts | that user's | every user's |
| `PATH`, links, file types, start with Windows | current user's registry | the computer's registry |
| Administrator prompt | never | once, at the start |

### Things to know before you choose it

* **No background updates.** A normal user can't write into Program Files, so the app can't update itself quietly. With [`[updates]`](/docs/guides/automatic-updates), leave `auto` out or set it to `"never"`. You can still check for updates from your app, and Windows asks for permission when one installs.
* **The folder must be inside Program Files.** Because the app runs and updates with administrator rights, setup refuses folders that other programs could change. If an old folder with loose permissions exists, setup says so; delete it or fix its permissions.
* **Deleting data** on uninstall only affects the account running the uninstaller, because data folders belong to one user.
* **Decide before your first release.** A per-user installation and a machine-wide one are two different installations to Windows. If you switch later, the update installs a second copy next to the first.
* **Windows services and firewall rules** need `scope = "machine"`. See [`[[services]]`](/docs/reference/config/services) and [`[[firewall]]`](/docs/reference/config/firewall).
* **Silent installs** need an elevated terminal or a deployment tool that runs as administrator. Otherwise Windows still shows its prompt, and declining it ends with exit code 1.

## Only one step needs administrator rights

If your app installs for one user but also has to run one program with administrator rights, such as a runtime installer, keep the default and elevate only that step. See [Run programs during setup](/docs/guides/run-programs.md).

## Check what you built

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
bach check
```

For a machine-wide app, the summary shows:

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
  Installs to  %ProgramFiles%\Hello Notes
  For          every user of the computer (asks for administrator rights once)
```

`bach preview` shows the window without asking for any rights.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.