> ## Documentation Index
> Fetch the complete documentation index at: https://docs.semgrep.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Create and manage unified policies

This document explains how to migrate existing policies to [unified policies](/semgrep-appsec-platform/unified-policies/overview), as well as how to create new unified policies.

## Migrate existing policies

<Steps>
  <Step>
    Sign in to [<Icon icon="external-link" iconType="solid" /> Semgrep AppSec Platform](https://semgrep.dev/login).
  </Step>

  <Step>
    Go to **Rules & Policies > Policies**. You will see a banner that prompts you to begin the upgrade to unified policies. Click to launch the **Upgrade to Unified Policies** dialog, and follow the on-screen prompts to proceed.
  </Step>

  <Step>
    Review the policies that Semgrep has migrated for you. For each product where you have existing policies, select the **I have reviewed these migration details** checkbox to proceed.
  </Step>

  <Step>
    When you have completed the migration process, you are redirected to the new **Policies** page, where you can manage your detection and remediation policies.
  </Step>
</Steps>

<note>
  <strong>Note:</strong> Email notifications are not supported by Unified Policies. If you currently have an email integration set up, no additional emails will be sent after you migrate to Unified Policies.
</note>

## Manage existing detection policies

<Steps>
  <Step>
    Sign in to [<Icon icon="external-link" iconType="solid" /> Semgrep AppSec Platform](https://semgrep.dev/login).
  </Step>

  <Step>
    Go to **Rules & Policies > Detection**. You can manage your policies for:

    * Code rules
    * Secrets rules
    * Supply Chain advisories
  </Step>

  <Step>
    Select the product for which you’d like to manage your Detection policy, and click **Edit**.
  </Step>

  <Step>
    Find the rules and rulesets you’d like to modify. Filters allow you to narrow the list of rules based on scanning behaviors, languages, rulesets, and more. You can also search for a rule using its name or label.
  </Step>

  <Step>
    To change the behavior of your rules:<br /><br />
    i. Select the rules by clicking the checkboxes next to their names, then click **Change scanning behavior (n)**. If you're modifying only one rule, you can click the rule’s link in the **Projects scanning** column.<br /><br />
    ii. The **Projects scanning** dialog appears. You can choose to use the rules with **All projects**, **Selected projects** by **Project name**, **Selected projects** by **Tags**, **All with exceptions**, or **None (disable)**.<br /><br />
    iii. To use the rules with all of your projects, click **All projects**, then click **Save**.<br /><br />
    iv. To use the rules with some of your projects, click **Selected projects**, then click the checkboxes next to the projects to which the rule applies. Click **Save** to proceed.<br /><br />
    v. To exclude specific projects, click **All with exceptions**, then select the projects to which the rule doesn’t apply. Click **Save** to proceed.<br /><br />
    vi. To prevent the rules from being used at all, click **None (Disable)**, then **Save** to proceed.
  </Step>
</Steps>

## Create a remediation policy

<Steps>
  <Step>
    Sign in to Semgrep AppSec Platform.
  </Step>

  <Step>
    Go to **Rules & Policies > Remediation**.
  </Step>

  <Step>
    To create a policy that defines the automated responses to security findings:<br /><br />
    i. Click **+ Create automation**.<br /><br />
    ii. Provide a **Policy name**.<br /><br />
    iii. Set the **Scope** of the policy by selecting all of the projects to which this policy applies.<br /><br />
    iv. Define the **Conditions** that trigger the policy by clicking **+ Add condition** to expand a drop-down list of attributes that you can use. Select the attribute, then set the specific conditions.

    * For example, you can select **Severity**, then complete the conditional statement provided to read **When Severity is any of Critical, High**.
    * You can define as many conditions as necessary, and Semgrep treats them additively.

    v. Choose the **Actions** that occur if there are findings that trigger the policy by clicking **+ Add action**. You can choose multiple **Actions**, including:

    <CardGroup>
      <Card title="Block merge and comment on PR/MR" icon="code-branch" href="/category/pr-or-mr-comments" horizontal />

      <Card title="Comment on PR/MR" icon="message" href="/category/pr-or-mr-comments" horizontal />

      <Card title="Create a JIRA ticket" icon="jira" href="/semgrep-appsec-platform/jira" horizontal />

      <Card title="Send a Slack message" icon="paper-plane" href="/semgrep-appsec-platform/slack-notifications" horizontal />

      <Card title="Call a webhook" icon="globe" href="/semgrep-appsec-platform/webhooks" horizontal />
    </CardGroup>

    vi. Click **Create & Enable** to save and proceed, so that Semgrep uses your new policy the next time you scan a project within its scope. Otherwise, click **Create** to save your changes without enabling the policy.
  </Step>
</Steps>
