Highcharts JS, the JavaScript charting framework
JavaScript HTML XSLT Java CSS PHP Other
Switch branches/tags
Clone or download
Permalink
Failed to load latest commit information.
changelog Tools: Changelog workflow readme. Aug 2, 2018
code Updated htaccess according to new ES modules. Nov 10, 2017
css Fixed #8241, use secure URLs in themes. Apr 26, 2018
errors Added clearer error reporting to offline exporting. Closes #8226. May 4, 2018
exporting-server Merge remote-tracking branch 'origin/master' into krevje Sep 21, 2016
gfx Finalized radial/circular gradients for VML Jun 27, 2012
js Fixed issue with order of dependencies between heatmap.js and treemap… Aug 2, 2018
samples Fixed #8659, treemap child nodes were not clickable due to wrong anim… Aug 1, 2018
studies Study: logo loading. Dec 20, 2017
test Update Firefox version Jul 31, 2018
tools Simplify requiring CDN Jul 31, 2018
utils Tools: Removed old utils PHP app, reviewed readmes, removed unused to… Mar 16, 2018
vendor Remove dot from generic syntax Jun 11, 2018
.eslintignore Done some changes based on the pull request feedback #8610 Aug 2, 2018
.eslintrc Allow nested ternary Apr 3, 2018
.gitignore Add JSDoc plugin for tree-namespace.json Jun 18, 2018
ISSUE_TEMPLATE.md Updated issue template to include version number. Jan 10, 2018
ant 3D: Changes and cleaning Feb 5, 2014
bower.json --- Highcharts 6.1.1 official release --- Jun 27, 2018
build.properties Cleaned up after v6.1.1. Jun 28, 2018
build.xml Tools: Removed redundant ant stuff from build.xml. Apr 9, 2018
cloud-downloader.js Utils: Prepared cloud samples downloader May 23, 2016
copy-release.js Fixed #7343, updated copy-to-release to automatically find and copy a… Nov 20, 2017
gulpfile.js Fixed generate-changelog so that it generates .md insted of .html fil… Aug 2, 2018
license.txt Fixed #7954, updated broken links in license.txt. Mar 6, 2018
node.svg --- Highcharts 4.2.0 official release --- Dec 15, 2015
package.json Done some changes based on the pull request feedback #8610 Aug 2, 2018
palette.html krevje: Palette preview Aug 18, 2016
readme.md Add doc generator info to readme.md Mar 23, 2018
repo-guidelines.md Guidelines Sep 13, 2017
temp.html Merge remote-tracking branch 'origin/master' into krevje May 10, 2016

readme.md

Highcharts JS is a JavaScript charting library based on SVG, with fallbacks to VML and canvas for old browsers.

Download and install Highcharts

This is the working repo for Highcharts. If you simply want to include Highcharts into a project, use the distribution package instead, or read the download page. Please note that there are several ways to use Highcharts. For general installation instructions, see the docs.

Use our CDN

Instead of downloading, you can use our CDN to access files directly. See code.highcharts.com for details.

<script src="https://code.highcharts.com/highcharts.js"></script>

Install from npm

See npm documentation on how to get started with npm.

npm install --save highcharts

Install from Bower

See Bower documentation on how to get started with Bower.

bower install highcharts

Load Highcharts as a CommonJS module

Highcharts is using an UMD module pattern, as a result it has support for CommonJS. The following examples presumes you are using npm to install Highcharts, see Download and install Highcharts for more details.

// Load Highcharts
var Highcharts = require('highcharts');
// Alternatively, this is how to load Highstock. Highmaps is similar.
// var Highcharts = require('highcharts/highstock');

// Load the exporting module, and initialize it.
require('highcharts/modules/exporting')(Highcharts);

// Generate the chart
Highcharts.chart('container', {
  // options - see https://api.highcharts.com/highcharts
});

Load Highcharts as an ES6 module

Since Highcharts supports CommonJS, it can be loaded as an ES6 module with the use of transpilers. Two common transpilers are Babel and TypeScript. These have different interpretations of a CommonJS module, which affects your syntax. The following examples presumes you are using npm to install Highcharts, see Download and install Highcharts for more details.

Babel

import Highcharts from 'highcharts';
// Alternatively, this is how to load Highstock. Highmaps is similar.
// import Highcharts from 'highcharts/highstock';

// Load the exporting module.
import Exporting from 'highcharts/modules/exporting';
// Initialize exporting module.
Exporting(Highcharts);

// Generate the chart
Highcharts.chart('container', {
  // options - see https://api.highcharts.com/highcharts
});

TypeScript

import * as Highcharts from 'highcharts';
// Alternatively, this is how to load Highstock. Highmaps is similar.
// import Highcharts from 'highcharts/highstock';

// Load the exporting module.
import * as Exporting from 'highcharts/modules/exporting';
// Initialize exporting module.
Exporting(Highcharts);

// Generate the chart
Highcharts.chart('container', {
  // options - see https://api.highcharts.com/highcharts
});

Build and debug

If you want to do modifications to Highcharts or fix issues, you may build your own files. Highcharts uses Gulp as the build system. After npm install in the root folder, run gulp, which will set up a watch task for the JavaScript and SCSS files. Now any changes in the files of the /js or /css folders will result in new files being built and saved in the code folder. Other tasks are also available, like gulp lint.

npm install
gulp

Generate API docs

Clone the repositories api-docs and highcharts-docstrap in the same parent folder as this highcharts repository. Do not forgett to install depending modules in this repositories by npm i. Finally you can run in this highcharts repository the doc generator with gulp jsdoc --watch, which also starts a new server with the generated API documentation.