# Setting up

# Introduction

To utilize all the features available in Chargebee.js, include the script on your webpage. Configurations for each feature need to be enabled and instantiated as appropriate.

# Including Chargebee.js

Include the following script in your HTML page. You need to do this only once per page.

<script src="https://js.chargebee.com/v2/chargebee.js"></script>
chargebee.js script should be loaded through Chargebee server for PCI compliance. DO NOT download and load it via your server.

# ​​Initializing Chargebee.js

Inside your JavaScript code, initialize chargebee once the page is loaded and get Chargebee instance object. This object can further be used for enabling payment integrations, analytics like Google Analytics and Facebook pixel tracking, checkout and portal integrations and more.

# Example:

  • jQuery
  • vue