Close Menu
Peter Klapwijk – In The Cloud 24-7Peter Klapwijk – In The Cloud 24-7
    Facebook X (Twitter) Instagram
    Peter Klapwijk – In The Cloud 24-7Peter Klapwijk – In The Cloud 24-7
    • Home
    • Intune
    • Windows
      • Modern Workplace
    • macOS
    • Android
    • iOS
    • Automation
      • Logic Apps
      • Intune Monitoring
      • GitHub
    • Security
      • Passwordless
      • Security
    • Speaking
    • About me
    Peter Klapwijk – In The Cloud 24-7Peter Klapwijk – In The Cloud 24-7
    Home»Intune»Update Microsoft Edge during Windows Autopilot enrollments
    Intune

    Update Microsoft Edge during Windows Autopilot enrollments

    Automatically update Microsoft Edge to the latest version
    Peter KlapwijkBy Peter KlapwijkJuly 9, 2024Updated:July 11, 202484 Mins Read

    Have you noticed that even the latest Windows 11 images are still shipped with Microsoft Edge version 92? An Edge release from June 2021!? Ridiculous if you ask me the Windows team doesn’t regularly update the version that they ship with Windows.

    As you can see below in the OOBE of a recent Windows 11 device, Edge version 92 is installed.

    Fortunately there is a pretty simple PowerShell one-liner with which we can trigger Edge to update to the latest available stable version. But it’s not know to everybody as it is hidden in some of the deployments documents from Microsoft. Therefor I share it here in this short post in the hope that more people can find it when they want to update Edge, for example during Windows Autopilot deployments.

    As you can see in the OOBE, with an internet connection of course 😉, we can run the command (1) and Edge is updated to the latest version (2).

    This means we should also be able to update Microsoft Edge automatically during Windows Autopilot enrollment using a PowerShell script.

    I created a very basic PowerShell script that does the job.
    But already soon after publishing the post, Mathieu Ait Azzouze left some comments under this post to make the script more dynamic. His changes are added to the script and handled in the post. This makes the IT community so great 🙂 Thanks for that, Mathieu!

    The script can be found on my Github repo.

    The script

    I added the PowerShell one-liner to a PowerShell script and wrapped that as WIN32 application. This way I can deploy it as application during Autopilot enrollment and if needed set it as dependency to another app. But you can also change the script to your own needs and deploy it as ‘normal’ script with Intune.

    It’s not a very long script, but let’s divide it into a few parts and look at what it does for us.

    As the Microsoft Intune Management Extension might start a 32-bit PowerShell instance, the script first restarts as 64-bit PS instance.

    In the functions region, we define a CleanUpAndExit function, which is also used for Intune detection when wrapped as a win32 package.

    In the variable section, we only have the variable for the Intune detection, that writes the result of the script to the registry. Change this to your own needs.

    The different Edge Update channels are defined. If needed you can change the channel and architecture in the param section. But during Autopilot enrollment you would update the stable channel.

    Next, we start the transcript, that writes some logging to the IntuneManagementExtension\Logs folder. By writing the logs to that folder, it is available when collecting Device diagnostics with Intune.

    Next, the script queries the Edge update API with an Invoke-Webrequest for the latest available version. We later use this retrieved version to determine if the latest version is installed after we trigger the update.

    Here we have the PowerShell one-liner that triggers Microsoft Edge to update to the latest version;
    Start-Process -FilePath “C:\Program Files (x86)\Microsoft\EdgeUpdate\MicrosoftEdgeUpdate.exe” -argumentlist “/silent /install appguid={56EB18F8-B008-4CBD-B6D2-8C97FE7E9062}&appname=Microsoft%20Edge&needsadmin=True”

    Next,I added a Do-Until to the script to check if the Edge version installed after the update matches the latest available Edge version.

    As last a clean up and exit action is added to write the results to the registry and it stops the transcript.

    And that’s all. Nothing exiting, but it does the job.

    Intune install and detection

    In case you also want to deploy the script as WIN32 applications I’ll show the install command and detection for this script.

    The install command is like this (depending on the PS1 file name):
    PowerShell.exe -ExecutionPolicy Bypass -file .\EdgeUpdateAutopilot.ps1

    And the detection rule that checks the registry:
    HKEY_LOCAL_MACHINE\Software\InTheCloud247\EdgeUpdateAutopilot\v1.1

    And that’s it for this short blog post.

    Thanks for reading!

    Automation Intune PowerShell Windows
    Share. Facebook Twitter LinkedIn Email WhatsApp
    Peter Klapwijk
    • Website
    • X (Twitter)
    • LinkedIn

    Peter is a Security (Intune) MVP since 2020 and is working as Modern Workplace Engineer at Wortell in The Netherlands. He has more than 15 years of experience in IT, with a strong focus on Microsoft technologies like Microsoft Intune, Windows, and (low-code) automation.

    Related Posts

    Configure Windows Update for Business reporting

    June 8, 2023

    How to change the Windows 11 language with Intune

    November 11, 2022

    Create Azure AD Dynamic Device Group using Mobile Device Management Type

    June 14, 2022
    View 8 Comments

    8 Comments

    1. Mathieu Ait Azzouzene on July 9, 2024 17:15

      Great post! Thanks

      I can’t believe MS doesn’t take time to update such a critical app within their new builds…

      If I have time I’ll update it to check Edge version online instead of checking if version is greater than 120 by parsing the following JSON.
      Invoke-WebRequest -uri ‘https://edgeupdates.microsoft.com/api/products?view=enterprise’

      Reply
      • Mathieu Ait Azzouzene on July 9, 2024 18:25

        First draft:
        $Product = ‘Stable’
        $Platform = ‘Windows’
        $architecture = ‘x64’
        $EdgeInfo = (Invoke-WebRequest -uri ‘https://edgeupdates.microsoft.com/api/products?view=enterprise’)
        $EdgeVersion = ((($EdgeInfo.content | Convertfrom-json) | ? {$_.product -eq $Product}).releases | ? {$_.Platform -eq $Platform -and $_.architecture -eq $architecture})[0].productversion

        Reply
        • Peter Klapwijk on July 10, 2024 10:04

          That’s a good one Mathieu!

          Only thing that needs to be added is UseBasicParsing as parameter, otherwise it gives an error during AP enrollment;

          The response content cannot be parsed because the Internet Explorer engine is not available, or Internet Explorer’s first-launch configuration is not complete. Specify the UseBasicParsing parameter and try again.

          Reply
    2. Michael O on July 12, 2024 16:48

      Good to know. We will try. Thanks.
      I think we will try to do it in a remediation script to regularly check the version and update if needed. Obsolete versions send us a security alert.

      We will search the same thing to update Chrome too.

      Reply
    3. Ben R on July 20, 2024 14:08

      Thanks for the script – not sure if it’s just me but although the version is 1.1, the $StoreResults variable is still creating the registry entry as “InTheCloud247\EdgeUpdateAutopilot\v1.0”, so the given detection rule for HKEY_LOCAL_MACHINE\Software\InTheCloud247\EdgeUpdateAutopilot\v1.1 is failing.

      Reply
      • Peter Klapwijk on July 28, 2024 14:02

        I fixed the typo in the script.

        Reply
    4. Habeeb on July 23, 2024 11:17

      FYI I need to add (Get-AppxPackage -AllUsers -Name “Microsoft.MicrosoftEdge.$UpdateChannel”).Version | Sort-Object -Descending | Select-Object -First 1 to your script when you queey versions. This is due to picking up multiple versions.

      Reply
    5. Ben on October 16, 2024 01:11

      I had the same issue as Habeeb. Get-AppxPackage was picking up multiple versions of Edge causing errors in the script, so I put the version results into an array and then picked the highest version from the array as my [System.Version]

      Reply
    Leave A Reply Cancel Reply

    Peter Klapwijk

    Hi! Welcome to my blog post.
    I hope you enjoy reading my articles.

    Hit the About Me button to get in contact with me or leave a comment.

    Awards
    Sponsor
    Latest Posts

    Hide the “Turn on an ad privacy feature” pop-up in Chrome with Microsoft Intune

    April 19, 2025

    How to set Google as default search provider with Microsoft Intune

    April 18, 2025

    Using Windows Autopilot device preparation with Windows 365 Frontline shared cloud PCs

    April 13, 2025

    Using Visual Studio with Microsoft Endpoint Privilege Management, some notes

    April 8, 2025
    follow me
    • Twitter 4.8K
    • LinkedIn 6.1K
    • YouTube
    Tags
    Administrative Templates Android Automation Autopilot Azure Azure AD Browser Conditional Access Edge EMS Exchange Online Feitian FIDO2 Flow Google Chrome Graph Graph API Identity Management Intune Intune Monitoring iOS KIOSK Logic Apps macOS MEM MEMMonitoring Microsoft 365 Microsoft Edge Microsoft Endpoint Manager Modern Workplace Office 365 OneDrive for Business Outlook Passwordless PowerApps Power Automate Security SharePoint Online Teams Windows Windows 10 Windows10 Windows 11 Windows Autopilot Windows Update
    Copy right

    This information is provided “AS IS” with no warranties, confers no rights and is not supported by the authors, or In The Cloud 24-7.

     

    Copyright © 2025 by In The Cloud 24-7/ Peter Klapwijk. All rights reserved, No part of the information on this web site may be reproduced or posted in any form or by any means without the prior written permission of the publisher.

    Shorthand; Don’t pass off my work as yours, it’s not nice.

    Recent Comments
    • Peter Klapwijk on Using Windows Autopilot device preparation with Windows 365 Frontline shared cloud PCs
    • John M on Using Windows Autopilot device preparation with Windows 365 Frontline shared cloud PCs
    • Christoffer Jakobsen on Connect to Azure file shares with Microsoft Entra Private Access
    • Ludo on How to block Bluetooth file transfer with Microsoft Intune
    • RCharles on Automatically configure the time zone (during Autopilot enrollment)
    most popular

    Application installation issues; Download pending

    October 1, 2024

    Restrict which users can logon into a Windows 10 device with Microsoft Intune

    April 11, 2020

    How to change the Windows 11 language with Intune

    November 11, 2022

    Update Microsoft Edge during Windows Autopilot enrollments

    July 9, 2024
    Peter Klapwijk – In The Cloud 24-7
    X (Twitter) LinkedIn YouTube RSS
    © 2025 ThemeSphere. Designed by ThemeSphere.

    Type above and press Enter to search. Press Esc to cancel.

    Manage Cookie Consent
    To provide the best experiences, we use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us to process data such as browsing behavior or unique IDs on this site. Not consenting or withdrawing consent, may adversely affect certain features and functions.
    Functional Always active
    The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
    Preferences
    The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
    Statistics
    The technical storage or access that is used exclusively for statistical purposes. The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
    Marketing
    The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.
    Manage options Manage services Manage {vendor_count} vendors Read more about these purposes
    View preferences
    {title} {title} {title}