# Legacy HTML Report

Legacy HTML Report from version 1 continues to function in version 2, but is planned to be deprecated soon. Please consider using the [**Cypress Image Diff HTML Report**](https://app.gitbook.com/o/boZ108LU5mrfWT6zkLtJ/s/ZyBQte7cOp75X6TWkWrZ/~/changes/17/getting-started/reporting/cypress-image-diff-html-report)**.**

For some reasons, you still want to use the legacy HTML report, add the following `after` hook:

```js
// cypress/support/index.js for Cypress versions below 10
// cypress/support/{scheme}.js for Cypress versions 10 and above, where {scheme} defaults to e2e
after(() => {
  cy.task('generateReport')
})
```

The report will look something like:

<figure><img src="/files/qa03M94nBSAqOupDhbTe" alt=""><figcaption></figcaption></figure>

*Note: Baseline, comparison and diff images will only be added to the report for failing tests.*

Legacy HTML report will be created following folder:

```
    .
    ├── cypress-image-diff-html-report
```

*Note: Report folder name for legacy HTML report can't be customized via REPORT\_DIR, it's hardcoded as `cypress-image-diff-html-report`.*


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://cypress.visual-image-diff.dev/getting-started/reporting/legacy-html-report.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
