In order for your Sitecore website to work, you need to have a valid license file. License files can only be obtained by spending the money and getting one from Sitecore. I’ve got this error and it’s usually because I’m installing Sitecore from source control on a new PC, or I’ve moved my Sitecore instances webroot to a new location.
When you install Sitecore through an installer, the license file will usually be copied into a Data folder in your Sitecore instance files. When running the website, if Sitecore can’t find this file, then the above error will occur.
How Do I Fix a Sitecore License Error?
Fixing the issue is pretty simple.. to get Sitecore up you need to tell your website to look in the right location for it. If you open your web.config and look in the ‘Sitecore’ section, you should see a property called ‘dataFolder’:
<sc.variable name="dataFolder" value="C:\Code\Website\Data\"/>
You need to make sure the value is pointing to the correct ‘Data’ location on your PC. In 95%of the cases this value is wrong. So after you make the change it should be a case of reloading your web page and everything working again.
If not then the next most likely cause of the issue, is a patch file in the ‘App_Config’ -> ‘Include’ that is intercepting the request and changing it Hint.. have a look for something called ‘DataFolder.config’. This may have a different ‘dataFolder’ path which is why your Sitecore instance can’t pick up your license. If you are still having issues after trying all the above, then it might be worth trying to run
www.website.com/sitecore/admin/showconfig.aspx. This page should tell you if the LicenseFile value is correct. If it’s not, it might be worth getting in contact with Sitecore to get a new license