A magnifying glass held over a trail of footprints, one print enlarged under the lens
Trusted third parties1 min read

Embed Chart.js on my site

Chart.js turns a small table of numbers into a bar, line or pie chart that draws itself on the page. Good for prices over time, class sizes or a simple survey result.

The prompt

Add a bar chart to the Results page showing our four courses and how many students finished each. Use Chart.js in our brand colours.

Signed in, Get my prompt fills in your site for you. Otherwise press Copy and fill in the [bracketed] parts. First time? Connect your AI to bernard once: Use your own AI (opens in a new tab).

Ask your AI

Add a bar chart to the Results page showing our four courses and how many students finished each. Use Chart.js in our brand colours.

What bernard checks

Chart.js is on bernard’s permitted list. Someone read the maker’s own instructions (https://www.chartjs.org/docs/latest/getting-started/) on 2026-09-14 and decided it was safe to run on a customer’s site: Constructor accepts a canvas id string, so no document.getElementById is needed. Formatter callbacks and plugins refused: they are functions. Your site loads it from its published package, version 4.4.0 or newer, at a version bernard pins and only ever moves forward.

Your AI writes the exact tag bernard permits, on a private preview. You look at it and approve it before anything goes live.

People search for this as: chart, graph, bar chart, pie chart, statistics.

For the full list of libraries, what is waiting, and how to ask for one that is not there, see Embed a calendar, a diagram, a chart or another tool on my site.

Questions people ask

Do I need to write any code to use Chart.js?
No. Your AI writes the exact tag bernard permits and puts it on a preview. You approve it before it goes live, and pasted code is removed for safety every time.
Is Chart.js safe on my site?
bernard admits it only from its own published address, with its settings written as plain data rather than code, at a version bernard pins and only ever moves forward. Nothing else about it can be changed from a page.
Can I change it later?
Yes. Say what you want different and your AI redoes it on a preview for you to approve. Nothing about it is baked in.

Next