---
title: Adding rewrite cookie path rules
description: Add a rewrite cookie path rule, which converts the cookie path returned by the site into a public-facing path, in PingAccess.
component: pingaccess
version: 8.2
page_id: pingaccess:pingaccess_user_interface_reference_guide:pa_adding_rewrite_cookie_path_rules
canonical_url: https://docs.pingidentity.com/pingaccess/9.1/pingaccess_user_interface_reference_guide/pa_adding_rewrite_cookie_path_rules.html
llms_txt: https://docs.pingidentity.com/pingaccess/llms.txt
docs_for_agents: https://developer.pingidentity.com/build-with-ai/docs-for-agents.md
revdate: January 12, 2024
superseded_by: https://docs.pingidentity.com/pingaccess/9.1/pingaccess_user_interface_reference_guide/pa_adding_rewrite_cookie_path_rules.html
section_ids:
  before-you-begin: Before you begin
  about-this-task: About this task
  steps: Steps
---

# Adding rewrite cookie path rules

Add a rewrite cookie path rule, which converts the cookie path returned by the site into a public-facing path, in PingAccess.

## Before you begin

Confirm that you are not using the [agent](../introduction_to_pingaccess/pa_agent_model.html) model. Rewrite cookie path rules aren't available for agent deployments.

## About this task

This task enables the details of exposed applications to be managed by PingAccess for security and request routing purposes.

For example, a site places a cookie in a server-facing cookie path such as `/content/`. Using the information configured in the rewrite cookie path rule, PingAccess rewrites the `Path` portion of the `Set-Cookie` response header with a public-facing cookie path such as `/importantstuff/`.

To add a rewrite cookie path rule:

## Steps

1. Click **Access**, then go to **Rules > Rules**.

2. Click **[icon: plus, set=fa]Add Rule**.

3. In the **Name** field, enter a unique name up to 64 characters.

   Special characters and spaces are allowed.

4. In the **Type** list, select **Rewrite Cookie Path**.

5. In the **Server-Facing Cookie Path** field, enter the path name where the cookie is valid for the backend site.

6. In the **Public-Facing Cookie Path** field, enter the path name that you want to display in the response from PingAccess.

7. Click **Save**.
