# Advanced: Create a Windows Installer EXE

If you need to install PixieBrix on Windows in an environment where Group Policies/ADMX are not supported, you can create an installer using the open-source Nullsoft Scriptable Install System (NSIS) framework.

The installer sets the [Windows Registry](/enterprise-it-setup/browser-extension-installation-and-configuration/browser-extension-installation-policy/windows-registry.md) keys, which control the browser extension installation and configuration policy.

### Example NSIS script for Chrome

```nsis
Name "PixieBrix Installer"
OutFile "PixieBrix-NoClient.exe"
RequestExecutionLevel admin  ; Require admin rights
SilentInstall silent

; Define pages only for non-silent installation
!include "MUI2.nsh"
!ifdef MUI_PAGE_DIRECTORY
    !insertmacro MUI_PAGE_DIRECTORY
!endif
!ifdef MUI_PAGE_INSTFILES
    !insertmacro MUI_PAGE_INSTFILES
!endif
!insertmacro MUI_LANGUAGE "English"

Var /GLOBAL SilentInstall

Function .onInit
    ; Check if the installer is running in silent mode
    StrCmp $CMDLINE "/S" 0 +2
    StrCpy $SilentInstall "true"
FunctionEnd

Section "Install Chrome Extension" SecExtension
    SetShellVarContext all  ; Set to affect all users

    ; Create the registry key if it doesn't exist
    WriteRegStr HKLM "SOFTWARE\Policies\Google\Chrome\ExtensionInstallForcelist" "10" "mpjjildhmpddojocokjkgmlkkkfjnepo;https://clients2.google.com/service/update2/crx"

    ; Display a finished message only if not silent
    StrCmp $SilentInstall "true" +2
    ; MessageBox MB_OK "Chrome extension has been successfully registered."
SectionEnd

Section "Uninstall"
    ; This is where uninstallation code would go, if necessary
    DeleteRegValue HKLM "SOFTWARE\Policies\Google\Chrome\ExtensionInstallForcelist" "10"
SectionEnd
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.pixiebrix.com/enterprise-it-setup/browser-extension-installation-and-configuration/browser-extension-installation-policy/advanced-create-a-windows-installer-exe.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
