Skip to main content

Configuration Options

Highcharts provides a powerful and flexible options system that allows you to customize every aspect of your charts. Understanding how to structure and apply options is key to creating professional visualizations.

Options Structure

Highcharts options are organized hierarchically in a configuration object:

Global Options

Set global options that apply to all charts using Highcharts.setOptions():

PlotOptions

Define default options for each series type using plotOptions:

Options Hierarchy

Understand how options are merged and prioritized:

Options Interface

TypeScript interface from Options.ts:

Common Configuration Patterns

Option Parameters Reference

string[]
Default colors for the chart’s series. Array of color strings (hex, rgb, rgba).
LangOptions
Language strings and settings for localization.
SeriesTypePlotOptions
Default plotting options for all series types and specific series types.
TooltipOptions
Options for the tooltip that appears when the user hovers over a series or point.
LegendOptions
The legend is a box containing a symbol and name for each series item or point item in the chart.
CreditsOptions
Highcharts by default puts a credits label in the lower right corner of the chart.
ExportingOptions
Options for the exporting module. Requires the exporting module to be loaded.

Real-World Examples

Dynamic Options Updates

Update chart options after initialization:

Best Practices

Use Highcharts.setOptions() for options that should apply to all charts in your application. This ensures consistency and reduces code duplication.
  1. Global Defaults - Set common options globally with setOptions()
  2. Type Safety - Use TypeScript interfaces for better IDE support
  3. Performance - Disable animations for charts with frequent updates
  4. Accessibility - Always include accessibility options for better UX
  5. Theming - Create reusable themes with setOptions()
Be careful when using Highcharts.setOptions() as it affects all charts created after the call. If you need chart-specific options, pass them in the chart constructor instead.

Next Steps

Chart Configuration

Learn about chart-specific options

Responsive Charts

Make charts adapt to screen size

Themes

Explore pre-built themes

API Reference

Complete options API documentation