> For the complete documentation index, see [llms.txt](https://docs.veza.com/4yItIzMvkpAvMVFAamTf/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.veza.com/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/how-to/compare-policy-versions.md).

# Compare Policy Versions

Review the differences between two versions of a Lifecycle Management policy, and export them to CSV

## Overview

Use **Compare Versions** to view what changed between two [versions of a policy](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/policies-workflows/policies.md#policy-version) before you publish a draft, or to review how a policy changed over time. The comparison lists every added, modified, and removed item, grouped by the part of the policy it belongs to, with the value in each version side by side.

For the layout of the policy page and the [version page](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/policies-workflows/policy-and-version-pages.md#version-page), see [Policy page and version page](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/policies-workflows/policy-and-version-pages.md).

## Before you start

* The policy must have more than one version. For a policy with one version, the ⋮ menu on the **Policies** page still shows **Compare Versions**, but the comparison shows only **Pick two different versions to see a comparison**.
* Comparing versions requires the Administrator or Operator role. See [Roles](/4yItIzMvkpAvMVFAamTf/administration/administration/users/roles.md).

## Compare two versions

1. Go to **Lifecycle Management** > **Policies**.
2. Open the ⋮ menu on the policy's row.
3. Under **Versions**, select **Compare Versions**.

   To start from the policy page instead, open the policy and select **Compare Versions** in the [**Policy Versions**](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/policies-workflows/policy-and-version-pages.md#policy-versions-panel) panel. The panel shows the button only when the policy has more than one version.
4. In **From**, select the earlier version. If the policy has a draft, **From** starts on the published version. If the policy has no draft, both pickers start on the published version, so select an earlier version here.
5. In **To**, select the later version. If the policy has a draft, **To** starts on the draft.

The page lists the changes by section, with a count of changes above the results, such as **12 Changes**.

Each picker entry shows the version number and, for the published version or a draft, its state, for example **From: Published (version v3)**. You can also select retired versions. A retired version shows no state, for example **From: (version v1)**.

If the same version is selected in **From** and **To**, the page shows **Pick two different versions to see a comparison**.

## Read the results

The page groups changes into sections and shows only the sections that contain changes:

* **Workflows**
* **Transformers**
* **Transformer Functions**
* **Alias Definitions** (early access; see [Alias Definitions](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/transformers.md#alias-definitions))
* **Lookup Tables**
* **Properties**
* **Password Complexity Rules**

Each section is a table with these columns:

| Column           | Description                                                |
| ---------------- | ---------------------------------------------------------- |
| **Name**         | The item that changed, such as a workflow or a transformer |
| **What Changed** | The setting or field that changed                          |
| **Change Type**  | **Added**, **Modified**, or **Removed**                    |
| **From**         | The value in the **From** version                          |
| **To**           | The value in the **To** version                            |

If the two versions have no differences, the page shows **No changes between the selected versions**.

### Filter the results

Use the filters above the results to narrow the list:

* **Workflow**: in the **Workflows** section, show only changes to the selected workflows. This filter does not affect the other sections.
* **Change Type**: show only **Added**, **Modified**, or **Removed** changes, or any combination of them.

If no changes match the filters, the page shows **No changes match the current filters**. Clear the filters to show all changes again.

## Export the comparison

1. Open the **Export** menu in the page header.
2. Select **Export to CSV**.

Veza downloads a file named `<policy name>_v<from>_vs_v<to>_changes.csv`, with spaces in the policy name replaced by underscores. The file contains the rows that match the current filters. It has a **Section** column followed by the **Name**, **What Changed**, **Change Type**, **From**, and **To** columns. In the CSV, **Change Type** holds `ADDED`, `MODIFIED`, or `REMOVED`.

The **Export** menu is not shown while the same version is selected in **From** and **To**, or when no changes match the filters.

## Next steps

* When the draft is ready, publish it from its version page. See [Header actions](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/policies-workflows/policy-and-version-pages.md#header-actions).
* To review every version of the policy, including retired versions, open [Version History](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/policies-workflows/policy-and-version-pages.md#version-history).

## See also

* [Policies](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/policies-workflows/policies.md)
* [Policy page and version page](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/policies-workflows/policy-and-version-pages.md)
* [Test policies with dry run](/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/how-to/test-policies-with-dry-run.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.veza.com/4yItIzMvkpAvMVFAamTf/features/lifecycle-management/how-to/compare-policy-versions.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
