Customer License Key Management

This page explains how to create and maintain license keys for prospects and customers.

Licensing Overview

Sourcegraph requires site administrators to apply a license key to access to various paid features. License keys are created and managed via the Site-admin > Enterprise subscriptions page on

Accessing Site Admin

License keys can only be generated by site administrators on To create or maintain a license you must request temporary access via Entitle (in Okta). Entitle grants temporary access to site admin.

  1. Go to Entitle via Okta

  2. Search for dotcom site-admin and select dotcom site-admin. Access is logged but automatically provisioned.

  3. If you are logged in to your dotcom account, reload the page so that your account updates to site-admin permissions.

    – NOTE: If you do not see site-admin permissions, check your profile settings -> Emails section and ensure that your email address is added to your profile, verified and it is set as primary. Or you can logout and login using Google Authentication into dotcom, this will create a new account for you with your email attached to it.

  4. On the top right click on your profile icon and the site admin menu will now be available for you to access.

  5. Go to Enterprise subscriptions.

License Key Mechanics

We require a unique license for every discrete instance. Non-production instances are supported but require a separate key (more on this below).

A license is comprised of the following components, we’ll go into each more in depth below:

  • User Account: every license needs associated to a “user account”. We create a company-level account for this.
  • Customer: this auto-populates based on the user account created above.
  • Salesforce Subscription ID: the ID of the active subscription (if relevant)
  • Salesforce Opportunity ID: the ID from the active opportunity the license is associated with. For both the Opportunity ID and Subscription ID (if relevant) the correct IDs can be found on the License IDs field on the Opportunity. It’s important to fill these in correctly for proper mapping and tracking.
  • Plan: the plan dictates what features the license has access to.
  • Tags: depending on the plan details you may need to add additional feature tags. Most commonly additional tags may be needed to allow for MAU plans or soft caps.
  • Users: the count of users provisioned for this license.
  • Expires At: the date at which the license expires.
    • NOTE: this expiration should match the contract, or in the case of a trial the agreed upon time frame of the trial.
    • NOTE: Licenses expire at midnight of the date selected based on the timezone of the browser where the license is being generated from. It is important to consider this as depending on the teammate location and the customer location you may need to actually set the expiration date to lag by a day.


Different plans have a unique feature-set included with them. In some instances you can manually apply additional tags to include additional features (more on this below) but typically simply selecting the plan covers everything you’ll need. Most frequently, CEs and TAs will be using the enterprise-1 plan for all Enterprise customers.

Below is an overview of the current supported plans and included features:

Plan Name Included Features
Code Search Enterprise Code Search, Batch Changes, Code Insights, Monitoring, Notebooks
Cody Enterprise Cody
Code Intelligence Platform Cody, Code Search, Batch Changes, Code Insights, Monitoring, Notebooks

Additional Options

Apart from the plan, there are a few additional options that can be added to a license key, depending on the license type.

Option Description
TrueUp Allows the instance to go over the user hard cap and be billed based on monthly usage
Allow air gapped Allows offline usage of Sourcegraph with no remote license key validation and telemetry off
Allow disable telemetry export Disables telemetry events export EXCEPT for Cody-related events, which we are always allowed to export as part of our Cody usage terms. To completely disable telemetry, allow air gapped usage

License Management Processes

Cloud Instances

Everything you need for creating and maintaining Cloud instances can be found here.

Activating Cody

Cody is available with our Cody Enterprise and Code Intelligence Platform licenses. When you create a license for either of those plans, you must also enable Access to hosted Cody Services from the Enterprise subscription page. Here, you can modify the chat and / or code completion limits per day and you can provision access to allowable models. Often, the default are sufficient and you simply need to toggle access on.

Zight 2024-3-29 at 10 09 30 AM

Prospective Customer Trials

For a new Sales-led trial, you’ll need to create a new subscription that will be used only for the trial period. (Follow the instructions for issuing a new license from start to finish.).

A note on Sales-led cloud (managed instance) trials: as part of the Managed Instance creation process, the CE should create a license key for the new instance and submit it with the GH issue request.

Converting a Prospect to a New Customer

When a prospect converts to a customer, you will need to create a new subscription; do not reuse the trial subscription. Follow the instructions for issuing a new license from start to finish. This is to ensure data accuracy for the Sales Ops team. Importantly, the Opportunity ID, Subscription ID and expiration need to match what’s in Salesforce and the contract.

Multiple Customer Instances

At times a customer may desire to have multiple instances. We use the instance feature tags to differentiate environments (eg, dev, test, qa, staging, production). As a best practice, create a single product subscription with multiple licenses to differentiate these environments. To do this:

  1. Go to the existing production subscription
  2. Click + generate new license manually and be sure to designate the correct instance tag

Note: if a customer needs multiple production instances you should create a separate product subscription for each.

Handling renewals or upgrades

If an existing company or customer needs a new license key for any reason (e.g., they purchase more seats, they upgrade product tiers, or they simply renew), the TA will add a new license key to the existing subscription. In that circumstance, do not click Create a product subscription; find the existing subscription on that page and then once viewing it, click Generate new license manually.

Visit the Site-admin > Enterprise subscriptions page, find the existing enterprise subscriptions, click into it, and follow the steps below (from the “Click Generate new license manually” step onwards).

  1. Sign in to and visit the Site-admin > Enterprise subscriptions page.
  2. Search for the user associated with the company, and click into the existing Enterprise subscription ID (left-most column). (You can also check for a user already exists following the instructions in the Internal Licensing FAQ document.)
  3. Click Generate new license manually. Fill out the license end date (most typically to match the contract terms) and fill in the appropriate license tags. For tags, see License Key Tags section. Tags must be separated by comma (spaces are ignored).
  4. Set the licensed number of users (note that if you added the true-up tag, the company will be able to exceed this count, but administrators will see a warning) and the end date for which the license should be valid, and click Generate license.
  5. Finally, copy the license key, and send it to the relevant contact at the company. You can link them to the following docs for instructions on where to add the key: Updating your license key

Reissuing Expired Licenses

In most circumstances, license keys match the renewal dates on an account contract and are generated well ahead of time. Sometimes, license keys deviate from this format due to product trials and other special circumstances. If a license key is imminently expiring or has expired, follow these steps:

  1. Check with the account’s Technical Advisor & Account Executive, as well as the Salesforce Account record and the account running notes. This will help you understand any special context surrounding the current license key tags and expiration dates.
  2. Grab the contract end date by going to the Account page in Salesforce to look up the "Active Contract Period End".
  3. Follow the process below for generating a renewal license key. Unless otherwise noted during Step 1, use the same exact tags and user count as the existing key (make sure to comma separate each tag) and use the "Active Contract Period End" as the expiration date.
  4. Send the new license key to the customer (follow the process outlined below).

Revoking an active license

In extreme circumstances, it may be required to revoke a customer’s active Sourcegraph license. This will mark the license as invalid on, and license verification checks from the customer’s Sourcegraph instance will fail, ultimately disabling all Sourcegraph Enterprise features.

To revoke an active license, follow these steps:

  1. Sign in to and visit the Site-admin > Enterprise subscriptions page.
  2. Navigate to the license that needs to be revoked.
  3. Click on the red Revoke button and provide a reason for the revocation.

The next time the customer’s instance performs a license verification check, the verification will fail and the customer’s Enterprise features will be disabled.

License Policies

License Key Sharing Policy

Within Sourcegraph we use 1Password for managing our credentials, including license keys. Follow these steps for safely sharing licensing credentials with customers.

  1. Create a new record in your private Vault (type = software license).
  2. Name the entry the customers’ name, enter the license key, and enter the admin’s email address. Click Save.
  3. Go to the newly created record and click Share. A prompt will be displayed with sharing options. Set the link to expire after 7 days, make it available only to some people, check the box for “Can be viewed only 1 time per person”, and enter the admin’s email address. Click Get Link to Share.
  4. Copy the private link that is generated and send to the admin. (Note: they must verify their email address to access the link).

Out of Contract License Extensions

In select circumstances, such as a bridge extension being requested due to the renewal process not aligning with license expiration, Sales must receive approval from the VP of Finance and VP of Sales to issue a licensing exception. This approval is granted via request in #deal-desk. If an AE requests a deviation from their contract licensing terms, please validate that the necessary approvals have been granted before making any changes to a customer’s license key.

Internal licensing FAQ

In case you have a question regarding licensing that is not discussed on this page, check if it is answered in the internal licensing FAQ. Or direct questions to the #licenses channel in slack.