Using Administrative Templates
Setting the Registry Using a Script
Getting Started
Please complete the registry settings for silent activation beforehand.
[Silent Activation] AD → Windows Chrome / Edge
There are various ways to configure the registry. If you already have a method in place to force (automatically) install any browser extensions, please use that same method.
Installing a device management tool agent (e.g., SKYSEA Client View) may add entries to the registry, but using administrative templates might overwrite those registry entries.
Please check the current status of the following registry paths beforehand:
HKLM:\SOFTWARE\Policies\Google\Chrome\ExtensionInstallForcelist
HKCU:\SOFTWARE\Policies\Google\Chrome\ExtensionInstallForcelist
HKLM:\SOFTWARE\Policies\Microsoft\Edge\ExtensionInstallForcelist
HKCU:\SOFTWARE\Policies\Microsoft\Edge\ExtensionInstallForcelist
The typical configuration methods are described below.
- If you know which extensions are configured: Configuring Registry Items
- If you already have configurations using administrative templates: Using Administrative Templates
- If you do not know which extensions are configured: Setting the Registry Using a Script
Configuring Registry Items
- Right-click "Group Policy Objects" and select "New".
- Enter a name and click "OK".
- Right-click the saved Group Policy and select "Edit".
- The "Group Policy Management Editor" window will open.
Go to "Computer Configuration" > "Preferences" > "Windows Settings" > "Registry", right-click, and select "New" > "Registry Item". - Configure the settings in the "New Registry Properties" window as follows. Once configured, click "OK".
Action: Update
Hive: HKEY_LOCAL_MACHINE
Key Path: SOFTWARE\Policies\Google\Chrome\ExtensionInstallForcelist
Value name: Any single-byte number (a number that does not conflict with other extensions)
Value type: REG_SZ
Value data: moaklgcgokbgplldonjkoochhlefkbjf;https://clients2.google.com/service/update2/crx - Link the Group Policy to the domain or OU. (The target is the computer object)
Right-click the target domain or OU and select "Link an Existing GPO...". - Select the created Group Policy and click "OK".
Using Administrative Templates
-
Open the
run.exeapplication. Right-click the Windows icon in the bottom-left corner of the screen and select [Run] from the menu. -
Open the Group Policy Management console.
TypeGPMC.mscand select [OK]. -
Create a new Group Policy Object (GPO). Right-click [Group Policy Objects] in the left navigation pane and select [New] from the menu. Name the policy something easy to understand, such as "josysExtInstall".
-
Right-click the new empty policy and select [Edit].
-
Navigate to [Policies] > [Administrative Templates: Policy definitions (ADMX files) retrieved from the central store] > [Google] > [Google Chrome] > [Extensions].
Next, open the following setting:
[Configure the list of force-installed apps and extensions].💡 If you cannot find the Chrome template, download the ADMX from the page below and upload it to the corresponding folder.
https://chromeenterprise.google/download/ -
Select [Extension/App IDs and update URLs to be silently installed] > [Show...].
Next, enter the extension ID and the update URL joined by a semicolon.
moaklgcgokbgplldonjkoochhlefkbjf;https://clients2.google.com/service/update2/crxSelect [OK], choose Enabled, and then select [Apply]. - Select the target devices and apply the GPO.
Setting the Registry Using a Script
-
Save the following script as a .ps1 file with a name of your choice (if saving with Notepad, UTF-8 with BOM is recommended).
*This script configures settings for both Chrome and Edge browsers.
*Edit as necessary.
This script will only leave a log file in the specified path if an error occurs.<# .SYNOPSIS Browser Extension Force Install Configuration Script .DESCRIPTION Adds entries to the ExtensionInstallForcelist for Google Chrome and Microsoft Edge. Supports execution with SYSTEM privileges, such as SKYSEA or AD startup scripts. .NOTES Describe the extension information you want to register in $ExtensionList in the settings area. #> #Requires -Version 5.1 #Requires -RunAsAdministrator # ----------------------------------------------------------- # [Settings Area] Extensions to install and log settings # ----------------------------------------------------------- # Log file path $LogFilePath = "C:\Windows\Temp\BrowserExtensionInstall.log" # List of target browsers and extension settings # Format: "ExtensionID;UpdateURL" # *Please replace the ID and URL according to your usage. $TargetExtensions = @( @{ Name = "Google Chrome" RegPath = "HKLM:\SOFTWARE\Policies\Google\Chrome\ExtensionInstallForcelist" # Example below: Josys ID Value = "moaklgcgokbgplldonjkoochhlefkbjf;https://clients2.google.com/service/update2/crx" }, @{ Name = "Microsoft Edge" RegPath = "HKLM:\SOFTWARE\Policies\Microsoft\Edge\ExtensionInstallForcelist" # Example below: Josys ID Value = "hjifncajikcdkhlofdjjlhcjoennmdfc;https://edge.microsoft.com/extensionwebstorebase/v1/crx" } ) # ----------------------------------------------------------- # Initialization # ----------------------------------------------------------- $script:HasError = $false try { Start-Transcript -Path $LogFilePath -Append -ErrorAction SilentlyContinue } catch { # Continue execution even if log start fails } Write-Host "--- Process Started: $(Get-Date) ---" Write-Host "Execution User: $env:USERNAME" # ----------------------------------------------------------- # Function Definition # ----------------------------------------------------------- function Set-BrowserExtension { param ( [string]$BrowserName, [string]$RegistryPath, [string]$ExtensionData ) Write-Host "`nChecking settings for [$BrowserName]..." try { # 1. Check and create path if (-not (Test-Path $RegistryPath)) { Write-Host " [INFO] Registry key does not exist, creating: $RegistryPath" New-Item -Path $RegistryPath -Force -ErrorAction Stop | Out-Null } # 2. Get existing values $existingProps = Get-ItemProperty -Path $RegistryPath -ErrorAction SilentlyContinue $numericNames = @() $isDuplicate = $false if ($existingProps) { # Duplicate check (compare by value content) foreach ($prop in $existingProps.PSObject.Properties) { if ($prop.Value -eq $ExtensionData) { $isDuplicate = $true Write-Host " [SKIP] Already registered (Entry: $($prop.Name))" break } } # Get existing sequential numbers (extract numeric names only) $numericNames = $existingProps.PSObject.Properties.Name | Where-Object { $_ -match "^\d+$" } | ForEach-Object { [int]$_ } | Sort-Object } # 3. New registration if (-not $isDuplicate) { # Calculate Max Value + 1 $nextNum = 1 if ($numericNames.Count -gt 0) { $nextNum = $numericNames[-1] + 1 } $newValueName = $nextNum.ToString() Write-Host " [ADD] Executing new registration: Name='$newValueName'" New-ItemProperty -Path $RegistryPath -Name $newValueName -Value $ExtensionData -PropertyType String -Force -ErrorAction Stop | Out-Null Write-Host " [SUCCESS] Registration completed" } } catch { Write-Error " [ERROR] An error occurred while processing $BrowserName: $($_.Exception.Message)" $script:HasError = $true } } # ----------------------------------------------------------- # Main Process # ----------------------------------------------------------- foreach ($target in $TargetExtensions) { Set-BrowserExtension -BrowserName $target.Name -RegistryPath $target.RegPath -ExtensionData $target.Value } Write-Host "`n--- Process Ended: $(Get-Date) ---" Stop-Transcript # ----------------------------------------------------------- # Post-processing (Log deletion check and ExitCode) # ----------------------------------------------------------- if ($script:HasError) { # If there is an error: Keep the log and return exit code 1 (Failure) Write-Warning "An error occurred during processing. Please check the log: $LogFilePath" exit 1 } else { # If there is no error: Delete the log and return exit code 0 (Success) Remove-Item -Path $LogFilePath -Force -ErrorAction SilentlyContinue exit 0 } - Configure the Group Policy so that the saved .ps1 file is executed as a startup script or similar.