---
schema_version: "1"
id: 25af073207dac1dd0dbe2136b7513b047c95a5deb5db2a5ccae151a930012404
title: Avoid Invalid Characters in Cookie Names
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/commerce/264-0-0/rn_cookie_combatibility_b2c_21_7_w9263644_je.md
canonical_url: https://help.salesforce.com/s/articleView?id=commerce.rn_cookie_combatibility_b2c_21_7_w9263644_je.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 7db2bc5f5e1a496e77accf4c10b4bb49bcb3138022f1ec302fadeee315dcdd9a
description: Starting with compatibility mode 21.7, using invalid characters in a cookie name causes dw.web.Cookie to throw an exception.
products:
  - Commerce
  - B2C Commerce
release: "264"
---
# Avoid Invalid Characters in Cookie Names

Starting with compatibility mode 21.7, using invalid characters in a cookie name causes `dw.web.Cookie` to throw an exception.

How: Invalid cookie characters are described in RFC6265, which references RFC2068.