More Information than You Require About Craft License Keys

Craft’s entire licensing system hinges on one little file: craft/config/license.key. Here’s everything you’ll ever need to know about them.

Origins #

A Craft install begins life without a license key. It is assigned one during its first request to the web service. That usually happens immediately after the installation process, when Craft first checks to see if any updates are available.

License keys are 250 randomly-generated characters. Craft saves its license key in craft/config/license.key, and refers to that file each time it makes a request to the web service.

With the license key in place, Craft is now considered licensed, even though it’s still running Personal Edition. Which brings us to…

Craft Editions #

Your Craft license doesn’t change when you upgrade to Client or Pro Edition. It just becomes associated with the new edition.

Wherever your license.key file goes, your Craft edition will follow. If you upgrade a Craft install on a development environment, and want your staging and production environments to be upgraded as well, just make sure they’re using the same license key.

Domains #

One Craft install can handle requests on multiple domains, with one caveat: you can only access the Control Panel on a single public domain. That’s because license verification happens in the Control Panel, and licenses can only be tied to a single public domain at a time.

A single license.key file does cover unlimited subdomains, however.

If you ever need to transfer a license to a new domain, we’ve made it easy.

Ownership #

As far as license verification is concerned, no one actually owns a Craft license key. Anyone who has access to a license.key file has the power to mess with it, delete it, or copy it to a new website. If there is a dispute over which Craft install a license key should be assigned to, we expect our customers to work it out like adults.

Gotchas #

Watch out for these common gotchas:

  • If you clone an existing Craft site as a starting point for a new one, don’t clone your license.key file. Let a new one be generated for the new site.

  • Deleting the contents of the license.key file will not cause a new one to be generated for you. You must delete the actual file.

  • Don’t give anyone access to the license.key file that you don’t trust or owe money to! Remember that everyone that has access to the license key can easily transfer it to a new domain.

Recovery #

If you accidentally lost or overwrote a license.key file that was tied to a Client/Pro Edition purchase, or need help with any other license-related questions, email support@craftcms.com and we’ll get you sorted.