Skip to main content
    All posts
    Intune
    WOW6432Node
    PowerShell
    Detection
    Win32 App

    Intune Detection Scripts Running 32-bit: How WOW64 Breaks PowerShell Detection in 2026

    Andrew MartyNovember 10, 20267 min read

    Your detection script finds the registry key every time you run it by hand. Deployed through Intune, it returns "not detected" on every device. The usual culprit is not the script logic: the Intune Management Extension launched it in 32-bit PowerShell, so HKLM:\SOFTWARE quietly resolved to WOW6432Node and the key you are looking for was never in that view.

    Fast Verdict Matrix

    ScenarioLegacy EXE + script behaviorNative MSI behavior
    Detection script hostRuns in 32-bit PowerShell unless "Run script as 32-bit process on 64-bit clients" is handled deliberately. Registry reads get redirected.MSI product-code detection needs no script and no PowerShell host at all.
    Install wrapper bitnessA wrapper launched from 32-bit PowerShell inherits WOW64 redirection for files (System32 becomes SysWOW64) and registry writes.msiexec.exe /i installs per the platform declared in the package.
    Uninstall lookupScripts that read one Uninstall hive miss entries in the other.msiexec.exe /x {ProductCode} works regardless of hive.
    MaintenanceBitness handling copy-pasted and re-tested per app.Nothing to maintain per app.

    The Rule of Thumb

    • Assume your script is running 32-bit until you have proven otherwise. Log [Environment]::Is64BitProcess in every detection and install script.
    • Prefer a detection method that has no host process. An MSI product code cannot be redirected, because there is no script to redirect.

    The Fix: Remove the Script From the Equation

    The conventional fix is more PowerShell: relaunch via $env:windir\sysnative\WindowsPowerShell\v1.0\powershell.exe, open [Microsoft.Win32.RegistryView]::Registry64 explicitly, or wrap the install in PSAppDeployToolkit. Each works, and each is one more thing to write, test on both bitnesses, and maintain per application.

    InstallMage converts the EXE into a native MSI and generates the detection rule from the MSI product code. There is no detection script to run in the wrong host and no PowerShell wrapper to carry bitness logic, so the 32-bit-vs-64-bit question never reaches your Intune assignment.

    Deep Dive

    Why Detection Scripts End Up 32-Bit

    The Intune Management Extension is a 32-bit service. For script-based detection and requirement rules, the "Run script as 32-bit process on 64-bit clients" setting controls the host. When it is set to Yes, or when a custom install command invokes powershell.exe by plain name from a 32-bit parent, you get SysWOW64\WindowsPowerShell. In that process Test-Path HKLM:\SOFTWARE\Vendor\App actually tests HKLM\SOFTWARE\WOW6432Node\Vendor\App.

    # Put this at the top of every detection/install script while debugging
    "{0} | 64-bit process: {1} | 64-bit OS: {2}" -f (Get-Date), [Environment]::Is64BitProcess, [Environment]::Is64BitOperatingSystem |
      Out-File "$env:ProgramData\Microsoft\IntuneManagementExtension\Logs\bitness-probe.log" -Append

    The File System Twin: System32 vs SysWOW64

    Registry redirection gets the attention, but the same layer remaps files. A 32-bit wrapper that copies a driver or helper into C:\Windows\System32 lands in SysWOW64. A detection script that checks C:\Program Files\Vendor\app.exe from a 32-bit host is redirected to Program Files (x86). The symptom is the same as the registry case: a clean exit code and a "not detected" result.

    The escape hatch is the sysnative alias, which only exists for 32-bit processes on 64-bit Windows. It is a useful workaround and a reliable way to write a script that works on your test VM and fails on a 32-bit-only edge case.

    What a Native MSI Does Differently

    Windows Installer records the package platform in the Template Summary property (Intel or x64) and each component declares its own 64-bit flag. The service performing the install handles registry views and directory redirection per component, independent of whichever shell launched msiexec. Detection by product code reads the Windows Installer database, not a hive, so there is nothing for WOW64 to redirect. Pair that with the WOW6432Node explainer and the detection rule comparison for the full decision tree.

    Frequently Asked Questions

    Why does my Intune detection script work in PowerShell ISE but fail when deployed?

    ISE and an admin console are usually 64-bit, while the Intune Management Extension may run the script as a 32-bit process. In 32-bit PowerShell, HKLM:\SOFTWARE is redirected to WOW6432Node, so the key you tested is not where the script looks. Check [Environment]::Is64BitProcess inside the script.

    What does "Run script as 32-bit process on 64-bit clients" do in Intune?

    It forces the detection or requirement script to run in 32-bit PowerShell on 64-bit Windows. Leave it set to No unless the script specifically needs 32-bit behavior, then confirm with a logged bitness check.

    How do I make Intune Win32 detection independent of 32-bit or 64-bit?

    Use an MSI product-code detection rule. It queries Windows Installer directly, so no registry view or PowerShell host is involved. InstallMage generates the MSI and the product-code rule from your EXE automatically.

    Keep reading