Search results

Register Syncfusion License key in EJ2-Angular application

24 May 2022 / 1 minute to read

Syncfusion license key should be registered, if your project using Syncfusion EJ2-Angular packages reference. The generated license key is a string that needs to be registered after any Syncfusion Angular reference.

Note: Syncfusion license validation is done offline during application execution and does not require internet access. Apps registered with a Syncfusion license key can be deployed on any system that does not have an internet connection.

The following code is used to register the license.


Register the license key in the main.ts file of the Angular project.

Copied to clipboard
import { enableProdMode } from '@angular/core';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';

import { AppModule } from './app/app.module';
import { environment } from './environments/environment';
import { registerLicense } from '@syncfusion/ej2-base';

// Registering Syncfusion license key
registerLicense('License Key');

if (environment.production) {

  .catch(err => console.error(err));

Note: Only from 2022 Vol 1 v20.1.0.47, license key registration required for Essential JavaScript 2 products.