en-US chrome computer user

Default cookies setting

Verified with Google Chrome — updated on July 10, 2026

Supported on: Microsoft Windows 7 or later

Path in the GPO console

Computer Configuration\Administrative Templates\Google\Google Chrome\Content settings

Description

Unless the RestoreOnStartup policy is set to permanently restore URLs from previous sessions, then setting CookiesSessionOnlyForUrls lets you make a list of URL patterns that specify sites that can and can't set cookies for one session. Leaving the policy unset results in the use of DefaultCookiesSetting for all sites, if it's set. If not, the user's personal setting applies. URLs not covered by the patterns specified also result in the use of defaults. While no specific policy takes precedence, see CookiesBlockedForUrls and CookiesAllowedForUrls. URL patterns among these 3 policies must not conflict.

Registry

HKLM Software\Policies\Google\Chrome
HKCU Software\Policies\Google\Chrome

More options available

Options

Default cookies setting
DefaultCookiesSetting enum
  • Allow all sites to set local data -> 1
  • Do not allow any site to set local data -> 2
  • Keep cookies for the duration of the session -> 4

Export Builder

BETA

Configure the state, scope and options, then generate .reg, PowerShell, Intune and SCCM outputs — or add the setting to a multi-setting collection.

These exports write the registry — this is not a managed GPO.

Scope

.reg file

Windows Registry Editor Version 5.00

; Exported from gporais.com
; Policy: Default cookies setting
; State: Enabled
; Scope: Computer (HKLM)
; Supported on: Microsoft Windows 7 or later

[HKEY_LOCAL_MACHINE\Software\Policies\Google\Chrome]
"DefaultCookiesSetting"=dword:00000001
More formats (PowerShell, Intune, SCCM)

PowerShell

# Exported from gporais.com
# Policy: Default cookies setting
# State: Enabled
# Scope: Computer (HKLM)
# Supported on: Microsoft Windows 7 or later

$path = 'HKLM:\Software\Policies\Google\Chrome'
New-Item -Path $path -Force | Out-Null
Set-ItemProperty -Path $path -Name 'DefaultCookiesSetting' -Value 1 -Type DWord

Building a multi-setting collection? Add this setting and generate combined .reg / PowerShell / GPO scripts.

Open the Builder

Embed this policy on your site

What to embed
Theme

Adds one script line: the theme follows your site’s appearance and the height fits the content. If your site blocks scripts, the embed follows the visitor’s system theme.

Preview