Organization owners can control which users in your organization can create and use codespaces at the organization's expense. For information about pricing, see "About billing for GitHub Codespaces."
Only people who can either push changes to a repository, or fork the repository, can create a codespace for that repository. To allow people to create codespaces for repositories owned by your organization, you must:
- Ensure that users have at least write access to the repositories where they want to use a codespace. For more information, see "Managing teams and people with access to your repository."
- Ensure that your organization does not have an IP address allow list enabled. For more information, see "Managing allowed IP addresses for your organization."
To allow people to create codespaces for which your organization will be billed, you must:
By default, a codespace can only access the repository from which it was created. If you want codespaces in your organization to be able to access other organization repositories that the codespace creator can access, see "Managing repository access for your organization's codespaces."
In the top right corner of GitHub.com, click your profile photo, then click Your organizations.
Next to the organization, click Settings.
In the left sidebar, click Codespaces.
Under "Billing," select one of the following options:
- Disabled - Your organization will not be charged for codespace usage. Codespaces created for your organization's repositories will be billed to the individual users who create them.
- Selected members - Codespaces created for your organization's repositories by selected members will be billed to the organization.
- All members - Codespaces created for your organization's repositories by members of your organization will be billed to the organization.
- All members and outside collaborators - Codespaces created for your organization's repositories by organization members and outside collaborators will be billed to the organization.
Note: When you select All members and outside collaborators, all outside collaborators who have been added to specific repositories can create and use Codespaces for those repositories, and your organization will be billed for this usage. For more information on managing outside collaborators, see "About outside collaborators."
If you chose Selected members, an input box is displayed for you to enter the names of users you want to select.
You can prevent the creation and use of codespaces billable to your organization.
Note: If you disable billing for GitHub Codespaces for some organization members and collaborators, or for your entire organization, anyone who can either push changes to, or fork, a repository in your organization, will still be able to create a codespace for that repository by using their personal account. However, this will not incur any charge for your organization. For information about restricting access to a repository, see "Managing teams and people with access to your repository."
- In the top right corner of GitHub.com, click your profile photo, then click Your organizations.
- Next to the organization, click Settings.
- In the left sidebar, click Codespaces.
- Under "Billing," select Disabled.
Note: You must set a non-zero spending limit on your personal, organization, or enterprise account before the account can be billed for use of GitHub Codespaces.
By default, all accounts have a GitHub Codespaces spending limit of $0 USD. This prevents new codespaces being created, or existing codespaces being opened, if doing so would incur a billable cost to your personal, organization, or enterprise account. For personal accounts, codespaces can always be created and used if the account has not reached the limit of its monthly included usage. For organizations and enterprises, the default spending limit means that, to allow people to create codespaces that are billed to the organization, or its parent enterprise, the limit must be changed to a value above $0 USD.
For information on managing and changing your account's spending limit, see "Managing your spending limit for Codespaces."