IronPdf License Keys
Removing the IronPDF Licensing Watermark
If you deploy IronPDF to a project outside of Visual Studio you will see a watermark appear on all the PDFs you produce. To remove this watermark immediately, you can purchase a license here.
You can also contact our team to request a 30 day trial deployment license if you need to test your live project prior to full deployment.
Using IronPdf License Keys
After you decide to purchase a license for IronPDF, you will instantly receive a license key as soon as your payment has cleared. This License will be displayed on the checkout screen and also be sent by email.
Setting your IronPdf license key using Code
Add this code to the startup of your application, before IronPDF is used. This method is universally effective and straight forwards. It works for .Net Core and also for .Net Framework applications.
IronPdf.License.LicenseKey = "IRONPDF-MYLICENSE-KEY-1EF01";
IronPdf.License.LicenseKey = "IRONPDF-MYLICENSE-KEY-1EF01";
IronPdf.License.LicenseKey = "IRONPDF-MYLICENSE-KEY-1EF01"
You can validate that your software is licensed using either IronPdf.License.IsValidLicense(string LicenseKey)
or the IronPdf.License.IsLicensed
property.
Setting your IronPdf license key using Web.Config or App.Config in .Net Framework Applications
To apply a key globally to your application using Web.Config or App.Config, add the following key to your config file in appSettings.
<configuration>
....
<appSettings>
<add key="IronPdf.LicenseKey" value="IRONPDF-MYLICENSE-KEY-1EF01"/>
</appSettings>
....
</configuration>
Ensure that IronPdf.License.IsLicensed
returns true
to verify.
Setting your IronPdf license key using a .Net Core appsettings.json file
To apply a key globally to your application to a .Net Core:
- Add a JSON file to your project called appsettings.json in the root directory of your project
- Add a 'IronPdf.LicenseKey' key to your JSON config file. The value should be your license key.
- Ensure that the file properties include Copy to Output Directory: Copy always
- Ensure that
IronPdf.License.IsLicensed
returnstrue
to verify.
File: appsettings.json
{
"IronPdf.LicenseKey":"IRONPDF-MYLICENSE-KEY-1EF01"
}
Test if your key has been installed correctly
// Check if a given license key string is valid.
bool result = IronPdf.License.IsValidLicense("IRONPDF-MYLICENSE-KEY-1EF01");
// Check if IronPdf is licensed successfully
bool is_licensed = IronPdf.License.IsLicensed;
// Check if a given license key string is valid.
bool result = IronPdf.License.IsValidLicense("IRONPDF-MYLICENSE-KEY-1EF01");
// Check if IronPdf is licensed successfully
bool is_licensed = IronPdf.License.IsLicensed;
' Check if a given license key string is valid.
Dim result As Boolean = IronPdf.License.IsValidLicense("IRONPDF-MYLICENSE-KEY-1EF01")
' Check if IronPdf is licensed successfully
Dim is_licensed As Boolean = IronPdf.License.IsLicensed
Note: After adding a license always remember to clean and republish you application to avoid potential mistakes in deployment.