> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.com/highcharts/highcharts/llms.txt
> Use this file to discover all available pages before exploring further.

# Quick Start Guide

> Create your first Highcharts visualization in under 5 minutes with this quick start guide.

## Create Your First Chart in 5 Minutes

This quick start guide will help you create a working chart with minimal setup. We'll use the CDN approach for simplicity.

<Note>
  This guide uses the CDN for quick setup. For production projects, consider using [npm installation](/installation#1-install-from-npm) instead.
</Note>

## Complete Example

Here's a complete HTML file that creates a column chart:

```html theme={null}
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>My First Highcharts</title>
  
  <!-- Load Highcharts from CDN -->
  <script src="https://code.highcharts.com/highcharts.js"></script>
</head>
<body>
  <!-- Container for the chart -->
  <div id="container" style="width:100%; height:400px;"></div>
  
  <script>
    // Create the chart
    document.addEventListener('DOMContentLoaded', function () {
      Highcharts.chart('container', {
        chart: {
          type: 'column'
        },
        title: {
          text: 'Corn vs Wheat Production 2023'
        },
        subtitle: {
          text: 'Source: indexmundi.com'
        },
        xAxis: {
          categories: ['USA', 'China', 'Brazil', 'EU', 'Argentina', 'India'],
          crosshair: true
        },
        yAxis: {
          min: 0,
          title: {
            text: '1000 metric tons (MT)'
          }
        },
        tooltip: {
          valueSuffix: ' (1000 MT)'
        },
        series: [
          {
            name: 'Corn',
            data: [387749, 280000, 129000, 64300, 54000, 34300]
          },
          {
            name: 'Wheat',
            data: [45321, 140000, 10000, 140500, 19500, 113500]
          }
        ]
      });
    });
  </script>
</body>
</html>
```

Copy this code into an HTML file and open it in your browser - you'll see a working chart!

## Step-by-Step Breakdown

<Steps>
  <Step title="Load Highcharts">
    Include the Highcharts library from the CDN:

    ```html theme={null}
    <script src="https://code.highcharts.com/highcharts.js"></script>
    ```

    <Note>
      For production, consider loading additional modules like accessibility:

      ```html theme={null}
      <script src="https://code.highcharts.com/modules/accessibility.js"></script>
      ```
    </Note>
  </Step>

  <Step title="Create a container">
    Add a `<div>` element where the chart will be rendered:

    ```html theme={null}
    <div id="container" style="width:100%; height:400px;"></div>
    ```

    The container needs an ID (used by Highcharts) and dimensions (width and height).
  </Step>

  <Step title="Initialize the chart">
    Call `Highcharts.chart()` with the container ID and configuration:

    ```javascript theme={null}
    document.addEventListener('DOMContentLoaded', function () {
      Highcharts.chart('container', {
        chart: { type: 'column' },
        title: { text: 'My Chart' },
        series: [{
          name: 'Sales',
          data: [1, 3, 2, 4]
        }]
      });
    });
    ```

    The `DOMContentLoaded` event ensures the page is fully loaded before creating the chart.
  </Step>
</Steps>

## Chart Types

Change the chart type by modifying the `chart.type` option:

<CodeGroup>
  ```javascript Line Chart theme={null}
  Highcharts.chart('container', {
    chart: { type: 'line' },
    title: { text: 'Monthly Sales' },
    xAxis: {
      categories: ['Jan', 'Feb', 'Mar', 'Apr', 'May']
    },
    series: [{
      name: 'Revenue',
      data: [29.9, 71.5, 106.4, 129.2, 144.0]
    }]
  });
  ```

  ```javascript Bar Chart theme={null}
  Highcharts.chart('container', {
    chart: { type: 'bar' },
    title: { text: 'Fruit Consumption' },
    xAxis: {
      categories: ['Apples', 'Bananas', 'Oranges']
    },
    series: [{
      name: 'Jane',
      data: [1, 0, 4]
    }, {
      name: 'John',
      data: [5, 7, 3]
    }]
  });
  ```

  ```javascript Pie Chart theme={null}
  Highcharts.chart('container', {
    chart: { type: 'pie' },
    title: { text: 'Browser Market Share' },
    series: [{
      name: 'Share',
      data: [
        { name: 'Chrome', y: 61.41 },
        { name: 'Firefox', y: 11.84 },
        { name: 'Safari', y: 10.85 },
        { name: 'Edge', y: 4.67 },
        { name: 'Other', y: 11.23 }
      ]
    }]
  });
  ```

  ```javascript Area Chart theme={null}
  Highcharts.chart('container', {
    chart: { type: 'area' },
    title: { text: 'Area Chart Example' },
    xAxis: {
      categories: ['Q1', 'Q2', 'Q3', 'Q4']
    },
    series: [{
      name: 'Revenue',
      data: [1000, 1200, 1400, 1100]
    }, {
      name: 'Costs',
      data: [800, 900, 950, 1000]
    }]
  });
  ```
</CodeGroup>

## Using with npm

If you prefer npm installation:

<Steps>
  <Step title="Install Highcharts">
    ```bash theme={null}
    npm install highcharts --save
    ```
  </Step>

  <Step title="Import and use">
    ```javascript theme={null}
    import Highcharts from 'highcharts';

    Highcharts.chart('container', {
      chart: { type: 'line' },
      title: { text: 'My Chart' },
      series: [{ data: [1, 2, 3, 4, 5] }]
    });
    ```
  </Step>
</Steps>

## Adding Interactivity

Enhance your chart with built-in features:

### Enable Exporting

Add the exporting module to let users download charts:

```html theme={null}
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<script src="https://code.highcharts.com/modules/export-data.js"></script>
```

This adds a menu button to export as PNG, JPEG, PDF, SVG, or CSV.

### Add Tooltips

Customize the tooltip that appears on hover:

```javascript theme={null}
Highcharts.chart('container', {
  tooltip: {
    pointFormat: '{series.name}: <b>{point.y}</b><br/>',
    valueSuffix: ' units'
  },
  // ... rest of config
});
```

### Enable Data Labels

Show values directly on the chart:

```javascript theme={null}
Highcharts.chart('container', {
  plotOptions: {
    series: {
      dataLabels: {
        enabled: true
      }
    }
  },
  // ... rest of config
});
```

## Stock Charts (Time Series)

For time-series data, use Highcharts Stock:

```html theme={null}
<script src="https://code.highcharts.com/stock/highstock.js"></script>

<div id="container" style="width:100%; height:400px;"></div>

<script>
Highcharts.stockChart('container', {
  rangeSelector: {
    selected: 1
  },
  title: {
    text: 'USD to EUR Exchange Rate'
  },
  series: [{
    name: 'USD to EUR',
    data: [
      [Date.UTC(2024, 0, 1), 0.85],
      [Date.UTC(2024, 1, 1), 0.87],
      [Date.UTC(2024, 2, 1), 0.86],
      [Date.UTC(2024, 3, 1), 0.88]
    ],
    tooltip: {
      valueDecimals: 2
    }
  }]
});
</script>
```

<Note>
  Stock charts use `Highcharts.stockChart()` instead of `Highcharts.chart()`.
</Note>

## Framework Integration

Highcharts works with popular frameworks:

<CodeGroup>
  ```jsx React theme={null}
  import Highcharts from 'highcharts';
  import HighchartsReact from 'highcharts-react-official';

  function MyChart() {
    const options = {
      title: { text: 'My Chart' },
      series: [{ data: [1, 2, 3, 4, 5] }]
    };
    
    return <HighchartsReact highcharts={Highcharts} options={options} />;
  }
  ```

  ```vue Vue theme={null}
  <template>
    <highcharts :options="chartOptions"></highcharts>
  </template>

  <script>
  import { Chart } from 'highcharts-vue';

  export default {
    components: { highcharts: Chart },
    data() {
      return {
        chartOptions: {
          title: { text: 'My Chart' },
          series: [{ data: [1, 2, 3, 4, 5] }]
        }
      };
    }
  };
  </script>
  ```

  ```typescript Angular theme={null}
  import * as Highcharts from 'highcharts';

  @Component({
    selector: 'app-chart',
    template: '<div id="container"></div>'
  })
  export class ChartComponent implements OnInit {
    ngOnInit() {
      Highcharts.chart('container', {
        title: { text: 'My Chart' },
        series: [{ data: [1, 2, 3, 4, 5] }]
      });
    }
  }
  ```
</CodeGroup>

See the [integrations overview](https://www.highcharts.com/integrations/) for official wrappers.

## Common Options

Here are the most commonly used configuration options:

| Option | Description | Example |
| - | - | - |
| `chart.type` | Chart type | `'line'`, `'bar'`, `'pie'`, `'column'` |
| `title.text` | Chart title | `'Monthly Revenue'` |
| `xAxis.categories` | X-axis labels | `['Jan', 'Feb', 'Mar']` |
| `yAxis.title.text` | Y-axis label | `'Sales ($)'` |
| `series` | Data series | `[{ name: 'Sales', data: [1, 2, 3] }]` |
| `tooltip` | Hover tooltip config | `{ valueSuffix: ' units' }` |
| `plotOptions` | Series-specific settings | `{ line: { marker: { enabled: false } } }` |

## Next Steps

<CardGroup cols={2}>
  <Card title="Your First Chart" icon="graduation-cap" href="/your-first-chart">
    Detailed tutorial with explanations of every option
  </Card>

  <Card title="API Reference" icon="book" href="/api/overview">
    Complete reference of all configuration options
  </Card>

  <Card title="Chart Types" icon="chart-mixed" href="/chart-types/line-area">
    Explore all available chart types
  </Card>

  <Card title="Examples" icon="images" href="/examples/basic-charts">
    Browse hundreds of live examples
  </Card>
</CardGroup>

<Note>
  For a more detailed walkthrough, continue to [Your First Chart](/your-first-chart) where we explain each configuration option in depth.
</Note>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.