# \[Launched\] Custom chart as code 📊

**URL:** <https://community.holistics.io/t/launched-custom-chart-as-code/2726>\
**Category:** Product Releases\
**Tags:** visualizations, canvas-dashboard\
**Created:** [June 25, 2026, 7:48am UTC](https://community.holistics.io/t/launched-custom-chart-as-code/2726 "2026-06-25T07:48:08Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Hien\_Nguyen\_Thanh](https://community.holistics.io/user_avatar/community.holistics.io/hien_nguyen_thanh/32/2233_2.png) [@Hien\_Nguyen\_Thanh](https://community.holistics.io/u/Hien_Nguyen_Thanh)\
**Post date:** [June 25, 2026, 7:48am UTC](https://community.holistics.io/t/launched-custom-chart-as-code/2726/1 "2026-06-25T07:48:09Z")

</div>

Hi team,

If you’ve built custom charts in Holistics, you know the friction: define the template in Admin Settings, switch to Explore to preview, and repeat. There’s no version history, syntax validation, or dependency checking.

This new update is for you!

## ✨ What’s new

Custom charts now live in AML. With this update, you can define them as code, create them through a GUI, and preview against real data:

- **Define as code:** Create a `CustomChart` block in a `.chart.aml` file. Charts are version-controlled in Git, syntax-validated, with dependency checks that prevent accidental deletion.
- **Easy creation flow:** Get started quickly using any of these three paths:
  - **Chat with AI:** Describe what you want, attach files (images, PDFs, etc.), or tag in-app context (datasets, dashboards, files) so AI has full context to generate your chart code.
  - **Pick a template:** Start with a pre-built chart layout and customize it to fit your data.
  - **Build from scratch:** Start from blank and write your custom code from the ground up.

- **Preview while editing** : As you write chart code, a preview panel renders the chart against real data. This lets you see and debug the output without leaving the editor.

## ⚠ Legacy migration

Legacy (non-as-code) custom charts still work as normal. Their definitions in Admin settings remain accessible for viewing, editing, and deletion, but all new charts must be defined as code.

We provide a path to generate the as code version of the legacy chart in the **Admin settings \> Custom charts \> Copy to Development**.

## 📚 Documentation

- [Custom charts](https://docs.holistics.io/docs/charts/custom-charts)
- [AML syntax reference](https://docs.holistics.io/reference/aml/custom-chart)
