> For the complete documentation index, see [llms.txt](https://developer.harness.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/insights.md).

# Workspace Insights

Start the Infrastructure Efficiency Loop here, from a cost or drift finding to a remediation pull request and a blast radius score.

Workspace Insights is where the Infrastructure Efficiency Loop starts. It surfaces cost and drift findings for a workspace, an agent opens a remediation pull request, and a blast radius score checks the risk before you apply the change. This closes the loop on optimizing your infrastructure for cost.

* **Cost findings:** These come from the [Cost Management Agent integration](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/cloud-cost-management-integration.md). A finding shows the actual cost of a resource and a savings recommendation.
* **Remediation:** Select **Apply with agent** to open a pull request with the [IaCM Remediation Agent](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/remediation-agent.md). You review and merge it. The agent does not change your infrastructure.

![Insights tab showing cost optimization recommendations with Apply with agent buttons](https://3575326923-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ffhx6XzjvtJmfv5gPWZ5m%2Fuploads%2Fgit-blob-996e6eb60ec5ebce264f85bd1306454568c7687e%2Finsights-ccm-open.png?alt=media)

***

## The Infrastructure Efficiency Loop

The Infrastructure Efficiency Loop connects finding an inefficiency to fixing it:

* **Detect:** The Insights tab lists cost findings and drift findings for the workspace.
* **Remediate:** Select **Apply with agent**. The [IaCM Remediation Agent](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/remediation-agent.md) opens a pull request with the fix.
* **Assess risk:** The [IaCM Blast Radius Agent](https://developer.harness.io/infrastructure-as-code-management/platform/iacm-pipelines/blast-radius-agent.md) scores the plan and shows which resources it affects.
* **Apply and track:** You review and merge the pull request, then provision the workspace. The **Applied** tab tracks the outcome.

***

## What you will learn from this topic <a href="#what-you-will-learn-from-this-topic" id="what-you-will-learn-from-this-topic"></a>

* How to open the Insights tab and read its summary cards.
* The difference between open and applied insights.
* How drift insights and cost optimization insights appear.
* Where the supported cost recommendation types are listed.
* How to start the remediation flow with the **Apply with agent** button.
* How the Infrastructure Efficiency Loop takes you from an insight to an applied fix.

***

## Open the Insights tab <a href="#open-the-insights-tab" id="open-the-insights-tab"></a>

Navigate to your workspace and select the **Insights** tab. The tab opens on the **Open** insights, with a count of open and applied insights shown at the top.

* **Open:** Insights that have been detected and not yet acted on.
* **Applied:** Insights for which the remediation pipeline has run and generated a pull request. Applied means a fix has been proposed, not that your infrastructure has already changed. The pull request still needs to be reviewed, merged, and the workspace provisioned before any infrastructure changes take effect.

***

## Insight summary cards <a href="#insight-summary-cards" id="insight-summary-cards"></a>

The cards at the top of the tab change depending on whether you are viewing open or applied insights.

**Open insights:**

* **All Insights:** The total number of insights detected for the workspace.
* **Optimization opportunity:** The estimated monthly savings across all cost recommendations, with the number of recommendations that contribute to it.
* **Resources drifted:** The number of resources that have drifted from your configuration.

**Applied insights:**

* **All Insights:** The total number of applied insights.
* **Savings realized:** The estimated monthly savings across all applied cost recommendations, with the number of recommendations that have had a pull request generated. This reflects proposed savings, not savings already realized in your infrastructure.
* **Drifts reconciled:** The number of drift insights for which a remediation pull request has been generated.

***

## Insight details <a href="#insight-details" id="insight-details"></a>

Each row in the insights list represents one finding. The columns describe the resource and the recommended fix.

**Open insights columns:**

* **Resource Name:** The affected resource. For cloud resources this typically includes the account, resource ID, and resource type.
* **Recommended Action/Resource:** The suggested fix (for example, **Rightsize** or **MigrateToGraviton**) and the resource type.
* **Saving Opportunity:** The estimated monthly savings and the percentage reduction for a cost recommendation. This is empty for drift insights.
* **Monthly Spend:** The current monthly spend for the resource, when cost data is available.

**Applied insights columns:**

* **Resource Name:** The affected resource.
* **Recommended Action/Resource:** The action that was applied.
* **Applied:** The date the remediation pipeline ran and the user who triggered it.
* **Monthly Savings:** The estimated monthly savings from the applied recommendation.
* **Status:** Whether the pipeline completed successfully (**SUCCESS**) or failed (**FAILED**). A failed row also shows a **Pipeline failed. Try to apply again** prompt.

### Drift insights <a href="#drift-insights" id="drift-insights"></a>

When a resource drifts from your OpenTofu or Terraform configuration, it appears as a **Drift detected** row with a **Drift reconciliation** recommended action. Click **Apply with agent** to start the remediation flow. Go to [IaCM Remediation Agent](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/remediation-agent.md) for the full workflow.

Drift insights are not limited to AWS or Azure. A drift run records an insight for each resource it reports as changed or deleted, for the provider on that resource. The Remediation Agent can open a pull request for that insight.

Go to [Drift detection](https://developer.harness.io/infrastructure-as-code-management/platform/iacm-pipelines/operations-overview.md) to understand how Harness IaCM detects drift.

### Cost optimization insights <a href="#cost-optimization-insights" id="cost-optimization-insights"></a>

A cost finding is one row: the recommended action, the estimated saving, and the current monthly spend. Select **View details in CCM** to open it in Cost Management. Select **Apply with agent** to open a pull request. Cost and recommendation sync includes AWS, Azure, and Google Cloud resources. The detail view has curated fields for AWS and Azure recommendation shapes. Drift insights are not part of that sync. Go to [IaCM Remediation Agent](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/remediation-agent.md) for the remediation flow. Go to [Cost Management Agent integration](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/cloud-cost-management-integration.md#recommendations) to turn the findings on and to see the supported recommendation types.

***

## Insight lifecycle

Each drift detection run updates the insights for the workspace based on the current drift state of each resource:

* **Open:** A resource that is still drifted keeps one Open insight. If a later run finds the same resource drifted, Harness updates the existing insight instead of creating another.
* **Removed:** If a later run finds that a resource is no longer drifted, Harness removes its Open insight.
* **Applied:** When you run the remediation pipeline for an insight, Harness marks it as Applied after the remediation run starts and a pull request is proposed. Harness does not track the pull request after it is created, so it does not know whether you merge it.
* **New Open insight:** Applied insights are not removed by later drift detection runs. If the resource is still drifted on a later run, Harness creates a new Open insight for the same resource alongside the Applied insight. This can happen if you have not merged the pull request or provisioned the workspace. Applying the new insight creates another pull request, which can duplicate the first. Merge or close the first pull request before you apply the new insight.
* **Failed:** A failed remediation run appears in the Applied view with **Pipeline failed. Try to apply again**. Open **Execution details** to review the logs, then click **Apply with agent** to retry the remediation.

***

## Applied insights <a href="#applied-insights" id="applied-insights"></a>

Select the **Applied** tab to review insights that have been remediated. The Applied view shows the same resources as the Open view but with additional columns tracking the outcome.

![Applied insights tab showing remediated cost recommendations with SUCCESS and FAILED statuses](https://3575326923-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ffhx6XzjvtJmfv5gPWZ5m%2Fuploads%2Fgit-blob-95e4595f958789bd1e72cd0e2c4090e1a849b1ea%2Finsights-ccm-applied.png?alt=media)

Each row shows:

* The date and user who triggered the remediation pipeline.
* The estimated monthly savings from the applied recommendation.
* A **SUCCESS** or **FAILED** status badge.
* Links to **Execution details** and the **PR** that was created.

If the pipeline failed, the row shows **Pipeline failed. Try to apply again**. Click **Apply with agent** again to re-run the remediation pipeline for that resource.

***

## Troubleshooting <a href="#troubleshooting" id="troubleshooting"></a>

<details>

<summary>No cost optimization insights appear on the Insights tab</summary>

Verify that Cloud Cost Management Integration is enabled in the workspace **Configuration** tab. CCM Integration syncs approximately every 12 hours, so recommendations may not appear immediately after enabling the toggle. Confirm that the Harness CCM module is active on your account and that the workspace manages AWS, Azure, or Google Cloud resources. Cost and recommendation sync includes all three. The detail view has curated fields for AWS and Azure recommendation shapes. Drift insights are not part of that sync.

</details>

<details>

<summary>The Insights tab says drift detection is not configured</summary>

This empty state is not about the Check for Drift pipeline. It appears when AI remediation is not enabled for the project and Cloud Cost Management Integration is not enabled on the workspace. When both features are available, the message is **Drift detection and CCM integration are currently not configured**. When only the Remediation Agent is available, the message is **Drift detection is currently not configured**. A completed drift run does not clear it.

Select **Setup Drift detection pipeline**. Harness opens **Project settings** > **IaCM Defaults** on the **AI Remediation Agent** section. Turn on **Enable AI Remediation for this project** and select **Enable**. Harness creates a pipeline named **IACM Remediation** with one Remediation Agent step and sets it as the project default. The message also clears when you enable Cloud Cost Management Integration on the workspace. Go to [Default pipelines](https://developer.harness.io/infrastructure-as-code-management/platform/iacm-pipelines/default-pipelines.md) for the remediation default.

</details>

<details>

<summary>The Apply with agent button is missing from an insight</summary>

Confirm a default remediation pipeline is configured for the project in the IaCM Defaults, and that the workspace is not excluded from remediation. Go to [IaCM Remediation Agent](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/remediation-agent.md) for setup details.

</details>

<details>

<summary>An applied insight shows a FAILED status</summary>

The row shows **Pipeline failed. Try to apply again**. Click **Execution details** to open the pipeline run and review the step logs. After resolving the issue, click **Apply with agent** again to re-run remediation for that resource.

</details>

***

## Next steps <a href="#next-steps" id="next-steps"></a>

* Go to [Cost Management Agent integration](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/cloud-cost-management-integration.md) to show cost findings on this tab.
* Go to [IaCM Remediation Agent](https://developer.harness.io/infrastructure-as-code-management/platform/workspaces/remediation-agent.md) to open a pull request from a finding.
* Go to [Drift detection](https://developer.harness.io/infrastructure-as-code-management/platform/iacm-pipelines/operations-overview.md) to configure drift detection.

{% @harness-feedback/feedback %}
