---
title: "Configure Grafana Alloy on Windows | Grafana Alloy documentation"
description: "Learn how to configure Grafana Alloy on Windows"
---

> For a curated documentation index, see [llms.txt](/llms.txt). For the complete documentation index, see [llms-full.txt](/llms-full.txt).

# Configure Grafana Alloy on Windows

To configure Alloy on Windows, perform the following steps:

1. Edit the default configuration file at `%PROGRAMFILES%\GrafanaLabs\Alloy\config.alloy`.
2. Restart the Alloy service:
   
   1. Open the Windows Services manager:
      
      1. Right click on the Start Menu and select **Run**.
      2. Type `services.msc` and click **OK**.
   2. Right click on the service called **Alloy**.
   3. Click on **All Tasks &gt; Restart**.

## Change command-line arguments

By default, the Alloy service will launch and pass the following arguments to the Alloy binary:

- `run`
- `%PROGRAMFILES%\GrafanaLabs\Alloy\config.alloy`
- `--storage.path=%PROGRAMDATA%\GrafanaLabs\Alloy\data`

To change the set of command-line arguments passed to the Alloy binary, perform the following steps:

1. Open the Registry Editor:
   
   1. Right click on the Start Menu and select **Run**.
   2. Type `regedit` and click **OK**.
2. Navigate to the key at the path `HKEY_LOCAL_MACHINE\SOFTWARE\GrafanaLabs\Alloy`.
3. Double-click on the value called **Arguments**\*.
4. In the dialog box, enter the arguments to pass to the Alloy binary. Make sure that each argument is on its own line.
5. Restart the Alloy service:
   
   1. Open the Windows Services manager:
      
      1. Right click on the Start Menu and select **Run**.
      2. Type `services.msc` and click **OK**.
   2. Right click on the service called **Alloy**.
   3. Click on **All Tasks &gt; Restart**.

## Change environment variable values

The Go runtime provides several ways to modify the execution of a binary using [environment variables](../../reference/cli/environment-variables/).

To change the environment variables used by Alloy, perform the following steps.

1. Open the Registry Editor:
   
   1. Right click on the Start Menu and select **Run**.
   2. Type `regedit` and click **OK**.
2. Navigate to the key at the path `HKEY_LOCAL_MACHINE\SOFTWARE\GrafanaLabs\Alloy`.
3. Double-click on the multi-string value called **Environment**\*.
4. In the dialog box, enter the environment variable values to pass to the Alloy binary. Make sure that each variable is on its own line.
5. Restart the Alloy service:
   
   1. Open the Windows Services manager (`services.msc`):
      
      1. Right click on the Start Menu and select **Run**.
      2. Type `services.msc` and click **OK**.
   2. Right click on the service called **Alloy**.
   3. Click on **All Tasks &gt; Restart**.

## Expose the UI to other machines

By default, Alloy listens on the local network for its HTTP server. This prevents other machines on the network from being able to access the [UI for debugging](../../troubleshoot/debug/#alloy-ui).

To expose the UI to other machines, complete the following steps:

1. Follow [Change command-line arguments](#change-command-line-arguments) to edit command line flags passed to Alloy.
2. Add the following command line argument:
   
   shell ![Copy code to clipboard](/media/images/icons/icon-copy-small-2.svg) Copy
   
   ```shell
   --server.http.listen-addr=LISTEN_ADDR:12345
   ```
   
   Replace the following:
   
   - *`<LISTEN_ADDR>`* : An IP address which other machines on the network have access to. For example, the IP address of the machine Alloy is running on.
     
     To listen on all interfaces, replace *`<LISTEN_ADDR>`* with `0.0.0.0`.

## Set Windows service access and permissions

For guidance on running Alloy with a dedicated service account, configuring Windows security group membership, and setting filesystem permissions, refer to [Access and permissions for Alloy on Windows](../../access_permissions/windows/).
