{"meta":{"title":"Codespaces documentation","intro":"Create a codespace to start developing in a secure, configurable, and dedicated development environment that works how and where you want it to.","product":"Codespaces","breadcrumbs":[{"href":"/en/codespaces","title":"Codespaces"}],"documentType":"product"},"body":"# Codespaces documentation\n\nCreate a codespace to start developing in a secure, configurable, and dedicated development environment that works how and where you want it to.\n\n## Recommended\n\n* [Quickstart for GitHub Codespaces](/en/codespaces/quickstart)\n\n  Get started with GitHub Codespaces quickly.\n\n* [What are GitHub Codespaces?](/en/codespaces/about-codespaces/what-are-codespaces)\n\n  Learn about what GitHub Codespaces are.\n\n* [Understanding the codespace lifecycle](/en/codespaces/about-codespaces/understanding-the-codespace-lifecycle)\n\n  Learn how to develop in a GitHub Codespaces environment, and maintain your data throughout the entire codespace lifecycle.\n\n* [Creating a codespace for a repository](/en/codespaces/developing-in-a-codespace/creating-a-codespace-for-a-repository)\n\n  You can create a codespace for a branch in a repository to develop online.\n\n* [Creating a codespace from a template](/en/codespaces/developing-in-a-codespace/creating-a-codespace-from-a-template)\n\n  If you're starting a new project, you can create a codespace from a blank template or choose a template specially designed for the type of work you want to do.\n\n* [Introduction to dev containers](/en/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/introduction-to-dev-containers)\n\n  When you work in a codespace, the environment you are working in is created using a development container, or dev container, hosted on a virtual machine.\n\n* [Using source control in your codespace](/en/codespaces/developing-in-a-codespace/using-source-control-in-your-codespace)\n\n  After making changes to a file in your codespace you can quickly commit the changes and push your update to the remote repository.\n\n* [Enabling or disabling GitHub Codespaces for your organization](/en/codespaces/managing-codespaces-for-your-organization/enabling-or-disabling-github-codespaces-for-your-organization)\n\n  You can control which users can use GitHub Codespaces in your organization's private repositories.\n\n* [Security in GitHub Codespaces](/en/codespaces/reference/security-in-github-codespaces)\n\n  Overview of the GitHub Codespaces security architecture, with guidelines to help you maintain security and minimize the risk of attack.\n\n## Links\n\n### Getting started\n\n* [What are GitHub Codespaces?](/en/codespaces/about-codespaces/what-are-codespaces)\n\n  Learn about what GitHub Codespaces are.\n\n* [Quickstart for GitHub Codespaces](/en/codespaces/quickstart)\n\n  Get started with GitHub Codespaces quickly.\n\n## Articles\n\n* [Quickstart for GitHub Codespaces](/en/codespaces/quickstart)\n\n  Get started with GitHub Codespaces quickly.\n\n* [What are GitHub Codespaces?](/en/codespaces/about-codespaces/what-are-codespaces)\n\n  Learn about what GitHub Codespaces are.\n\n* [GitHub Codespaces features](/en/codespaces/about-codespaces/codespaces-features)\n\n  Learn about what GitHub Codespaces offer.\n\n* [Understanding the codespace lifecycle](/en/codespaces/about-codespaces/understanding-the-codespace-lifecycle)\n\n  Learn how to develop in a GitHub Codespaces environment, and maintain your data throughout the entire codespace lifecycle.\n\n* [Deep dive into GitHub Codespaces](/en/codespaces/about-codespaces/deep-dive)\n\n  Explore more detail about how GitHub Codespaces work.\n\n* [Developing in a codespace](/en/codespaces/developing-in-a-codespace/developing-in-a-codespace)\n\n  You can work in a codespace using your browser, Visual Studio Code, or in a command shell.\n\n* [Creating a codespace for a repository](/en/codespaces/developing-in-a-codespace/creating-a-codespace-for-a-repository)\n\n  You can create a codespace for a branch in a repository to develop online.\n\n* [Creating a codespace from a template](/en/codespaces/developing-in-a-codespace/creating-a-codespace-from-a-template)\n\n  If you're starting a new project, you can create a codespace from a blank template or choose a template specially designed for the type of work you want to do.\n\n* [Deleting a codespace](/en/codespaces/developing-in-a-codespace/deleting-a-codespace)\n\n  You can delete a codespace you no longer need.\n\n* [Opening an existing codespace](/en/codespaces/developing-in-a-codespace/opening-an-existing-codespace)\n\n  You can reopen a codespace that you have closed or stopped and return to your work.\n\n* [Working collaboratively in a codespace](/en/codespaces/developing-in-a-codespace/working-collaboratively-in-a-codespace)\n\n  You can work collaboratively with other people in a codespace by using Visual Studio Live Share.\n\n* [Using source control in your codespace](/en/codespaces/developing-in-a-codespace/using-source-control-in-your-codespace)\n\n  After making changes to a file in your codespace you can quickly commit the changes and push your update to the remote repository.\n\n* [Using GitHub Codespaces for pull requests](/en/codespaces/developing-in-a-codespace/using-github-codespaces-for-pull-requests)\n\n  You can use GitHub Codespaces in your web browser, or in Visual Studio Code to create pull requests, review pull requests, and address review comments.\n\n* [Stopping and starting a codespace](/en/codespaces/developing-in-a-codespace/stopping-and-starting-a-codespace)\n\n  You can stop and start your codespace to save resources and to pause work.\n\n* [Forwarding ports in your codespace](/en/codespaces/developing-in-a-codespace/forwarding-ports-in-your-codespace)\n\n  You can forward ports in your codespace to test and debug your application. You can also manage the port protocol and share the port within your organization or publicly.\n\n* [Rebuilding the container in a codespace](/en/codespaces/developing-in-a-codespace/rebuilding-the-container-in-a-codespace)\n\n  You can rebuild the dev container of a codespace you are working in to apply configuration changes. From time to time, you may want to perform a full rebuild.\n\n* [Default environment variables for your codespace](/en/codespaces/developing-in-a-codespace/default-environment-variables-for-your-codespace)\n\n  GitHub sets default environment variables for each codespace.\n\n* [Persisting environment variables and temporary files](/en/codespaces/developing-in-a-codespace/persisting-environment-variables-and-temporary-files)\n\n  You can configure custom environment variables so that they are set to the same value every time you open a codespace. You can also ensure that temporary files are not deleted when a codespace stops.\n\n* [Connecting to a private network](/en/codespaces/developing-in-a-codespace/connecting-to-a-private-network)\n\n  You can connect GitHub Codespaces to resources on a private network, including package registries, license servers, and on-premises databases.\n\n* [Getting started with GitHub Codespaces for machine learning](/en/codespaces/developing-in-a-codespace/getting-started-with-github-codespaces-for-machine-learning)\n\n  Learn about working on machine learning projects with GitHub Codespaces and its out-of-the-box tools.\n\n* [Using GitHub Codespaces in Visual Studio Code](/en/codespaces/developing-in-a-codespace/using-github-codespaces-in-visual-studio-code)\n\n  You can develop in your codespace directly in Visual Studio Code by connecting the GitHub Codespaces extension with your GitHub account.\n\n* [Using GitHub Codespaces with GitHub CLI](/en/codespaces/developing-in-a-codespace/using-github-codespaces-with-github-cli)\n\n  You can work with GitHub Codespaces directly from your command line by using `gh`, the GitHub command line interface.\n\n* [Renaming a codespace](/en/codespaces/customizing-your-codespace/renaming-a-codespace)\n\n  You can change the codespace display name to one of your choice on GitHub or using the GitHub CLI.\n\n* [Changing the shell in a codespace](/en/codespaces/customizing-your-codespace/changing-the-shell-in-a-codespace)\n\n  You can change your shell in a codespace to keep the setup you're used to.\n\n* [Changing the machine type for your codespace](/en/codespaces/customizing-your-codespace/changing-the-machine-type-for-your-codespace)\n\n  You can change the type of machine that's running your codespace, so that you're using resources appropriate for the work you're doing.\n\n* [Personalizing GitHub Codespaces for your account](/en/codespaces/setting-your-user-preferences/personalizing-github-codespaces-for-your-account)\n\n  You can personalize GitHub Codespaces by using a `dotfiles` repository on GitHub or by using Settings Sync.\n\n* [Setting your default editor for GitHub Codespaces](/en/codespaces/setting-your-user-preferences/setting-your-default-editor-for-github-codespaces)\n\n  You can set your default editor for Codespaces in your personal settings page.\n\n* [Setting your default region for GitHub Codespaces](/en/codespaces/setting-your-user-preferences/setting-your-default-region-for-github-codespaces)\n\n  You can set your default region in the GitHub Codespaces profile settings page to personalize where your data is held.\n\n* [Setting your timeout period for GitHub Codespaces](/en/codespaces/setting-your-user-preferences/setting-your-timeout-period-for-github-codespaces)\n\n  You can set your default timeout for GitHub Codespaces in your personal settings page.\n\n* [Configuring automatic deletion of your codespaces](/en/codespaces/setting-your-user-preferences/configuring-automatic-deletion-of-your-codespaces)\n\n  Inactive codespaces are automatically deleted. You can choose how long your stopped codespaces are retained, up to a maximum of 30 days.\n\n* [Choosing the stable or beta host image](/en/codespaces/setting-your-user-preferences/choosing-the-stable-or-beta-host-image)\n\n  You can choose to build codespaces using either the stable or beta version of the host image for the underlying virtual machine.\n\n* [Introduction to dev containers](/en/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/introduction-to-dev-containers)\n\n  When you work in a codespace, the environment you are working in is created using a development container, or dev container, hosted on a virtual machine.\n\n* [Setting up a Node.js project for GitHub Codespaces](/en/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/setting-up-your-nodejs-project-for-codespaces)\n\n  Get started with a Node.js, JavaScript, or TypeScript project in GitHub Codespaces by creating a custom dev container configuration.\n\n* [Setting up a C# (.NET) project for GitHub Codespaces](/en/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/setting-up-your-dotnet-project-for-codespaces)\n\n  Get started with a C# (.NET) project in GitHub Codespaces by creating a custom dev container configuration.\n\n* [Setting up a Java project for GitHub Codespaces](/en/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/setting-up-your-java-project-for-codespaces)\n\n  Get started with a Java project in GitHub Codespaces by creating a custom dev container configuration.\n\n* [Setting up a PHP project for GitHub Codespaces](/en/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/setting-up-your-php-project-for-codespaces)\n\n  Get started with a PHP project in GitHub Codespaces by creating a custom dev container configuration.\n\n* [Setting up a Python project for GitHub Codespaces](/en/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/setting-up-your-python-project-for-codespaces)\n\n  Get started with a Python project in GitHub Codespaces by creating a custom dev container configuration.\n\n* [Setting a minimum specification for codespace machines](/en/codespaces/setting-up-your-project-for-codespaces/configuring-dev-containers/setting-a-minimum-specification-for-codespace-machines)\n\n  You can avoid under-resourced machine types being used for GitHub Codespaces for your repository.\n\n* [Adding features to a devcontainer.json file](/en/codespaces/setting-up-your-project-for-codespaces/configuring-dev-containers/adding-features-to-a-devcontainer-file)\n\n  With features, you can quickly add tools, runtimes, or libraries to your dev container configuration.\n\n* [Automatically opening files in the codespaces for a repository](/en/codespaces/setting-up-your-project-for-codespaces/configuring-dev-containers/automatically-opening-files-in-the-codespaces-for-a-repository)\n\n  You can set particular files to be opened automatically whenever someone creates a codespace for your repository and opens the codespace in the Visual Studio Code web client.\n\n* [Specifying recommended secrets for a repository](/en/codespaces/setting-up-your-project-for-codespaces/configuring-dev-containers/specifying-recommended-secrets-for-a-repository)\n\n  You can add a setting to your dev container configuration that will prompt people to set specific development environment secrets when they create a codespace.\n\n* [Facilitating quick creation and resumption of codespaces](/en/codespaces/setting-up-your-project-for-codespaces/setting-up-your-repository/facilitating-quick-creation-and-resumption-of-codespaces)\n\n  You can add a link to take people straight to a page for creating a codespace, with your choice of options preconfigured. Alternatively you can link to the \"Resume codespace\" page.\n\n* [Setting up a template repository for GitHub Codespaces](/en/codespaces/setting-up-your-project-for-codespaces/setting-up-your-repository/setting-up-a-template-repository-for-github-codespaces)\n\n  You can help people get started with a project by setting up a template repository for use with GitHub Codespaces.\n\n* [About GitHub Codespaces prebuilds](/en/codespaces/prebuilding-your-codespaces/about-github-codespaces-prebuilds)\n\n  GitHub Codespaces prebuilds help to speed up the creation of new codespaces for large or complex repositories.\n\n* [Configuring prebuilds](/en/codespaces/prebuilding-your-codespaces/configuring-prebuilds)\n\n  You can configure your project to prebuild a codespace automatically each time you push a change to your repository.\n\n* [Allowing a prebuild to access other repositories](/en/codespaces/prebuilding-your-codespaces/allowing-a-prebuild-to-access-other-repositories)\n\n  You can permit your prebuild to access other GitHub repositories so that it can be built successfully.\n\n* [Managing prebuilds](/en/codespaces/prebuilding-your-codespaces/managing-prebuilds)\n\n  You can review, modify, and delete the prebuild configurations for your repository.\n\n* [Testing dev container configuration changes on a prebuild-enabled branch](/en/codespaces/prebuilding-your-codespaces/testing-dev-container-changes)\n\n  When you change the dev container configuration for a branch that's enabled for prebuilds, you should test your changes in a codespace.\n\n* [Managing your account-specific secrets for GitHub Codespaces](/en/codespaces/managing-your-codespaces/managing-your-account-specific-secrets-for-github-codespaces)\n\n  You can store sensitive information, like tokens, that you want to access in your codespaces via environment variables.\n\n* [Managing access to other repositories within your codespace](/en/codespaces/managing-your-codespaces/managing-repository-access-for-your-codespaces)\n\n  You can manage the repositories that GitHub Codespaces can access.\n\n* [Reviewing your security logs for GitHub Codespaces](/en/codespaces/managing-your-codespaces/reviewing-your-security-logs-for-github-codespaces)\n\n  You can use the security log to review all actions related to GitHub Codespaces.\n\n* [Managing GPG verification for GitHub Codespaces](/en/codespaces/managing-your-codespaces/managing-gpg-verification-for-github-codespaces)\n\n  You can allow GitHub to automatically use GPG to sign commits you make in your codespaces, so other people can be confident that the changes come from a trusted source.\n\n* [Enabling or disabling GitHub Codespaces for your organization](/en/codespaces/managing-codespaces-for-your-organization/enabling-or-disabling-github-codespaces-for-your-organization)\n\n  You can control which users can use GitHub Codespaces in your organization's private repositories.\n\n* [Choosing who owns and pays for codespaces in your organization](/en/codespaces/managing-codespaces-for-your-organization/choosing-who-owns-and-pays-for-codespaces-in-your-organization)\n\n  You can choose whether codespaces are paid for and owned by your organization or by your members.\n\n* [Listing the codespaces in your organization](/en/codespaces/managing-codespaces-for-your-organization/listing-the-codespaces-in-your-organization)\n\n  You can list all of the currently active or stopped codespaces for your organization.\n\n* [Managing the cost of GitHub Codespaces in your organization](/en/codespaces/managing-codespaces-for-your-organization/managing-the-cost-of-github-codespaces-in-your-organization)\n\n  You can check your GitHub Codespaces usage and set usage limits.\n\n* [Managing development environment secrets for your repository or organization](/en/codespaces/managing-codespaces-for-your-organization/managing-development-environment-secrets-for-your-repository-or-organization)\n\n  Development environment secrets allow you to store sensitive information in your organization or repository for use with GitHub Codespaces.\n\n* [Reviewing your organization's audit logs for GitHub Codespaces](/en/codespaces/managing-codespaces-for-your-organization/reviewing-your-organizations-audit-logs-for-github-codespaces)\n\n  You can use the audit log to review all actions related to GitHub Codespaces.\n\n* [Restricting access to machine types](/en/codespaces/managing-codespaces-for-your-organization/restricting-access-to-machine-types)\n\n  You can set constraints on the types of machines users can choose when they create codespaces in your organization.\n\n* [Restricting the number of organization-billed codespaces a user can create](/en/codespaces/managing-codespaces-for-your-organization/restricting-the-number-of-organization-billed-codespaces-a-user-can-create)\n\n  You can specify the maximum number of codespaces that any member of your organization, or collaborator, can create for the repositories in your organization.\n\n* [Restricting the base image for codespaces](/en/codespaces/managing-codespaces-for-your-organization/restricting-the-base-image-for-codespaces)\n\n  You can specify which base images can be used to create the dev container for new codespaces created within your organization.\n\n* [Restricting the visibility of forwarded ports](/en/codespaces/managing-codespaces-for-your-organization/restricting-the-visibility-of-forwarded-ports)\n\n  You can set constraints on the visibility options users can choose when they forward ports from codespaces in your organization.\n\n* [Restricting the idle timeout period](/en/codespaces/managing-codespaces-for-your-organization/restricting-the-idle-timeout-period)\n\n  You can set a maximum timeout period for any codespaces owned by your organization.\n\n* [Restricting the retention period for codespaces](/en/codespaces/managing-codespaces-for-your-organization/restricting-the-retention-period-for-codespaces)\n\n  You can set a maximum retention period for any codespaces owned by your organization.\n\n* [Allowing your codespace to access a private registry](/en/codespaces/reference/allowing-your-codespace-to-access-a-private-registry)\n\n  You can allow GitHub Codespaces to access container images or other packages in a private registry.\n\n* [Using GitHub Copilot in GitHub Codespaces](/en/codespaces/reference/using-github-copilot-in-github-codespaces)\n\n  You can use GitHub Copilot in GitHub Codespaces by adding a VS Code extension.\n\n* [Using the Visual Studio Code Command Palette in GitHub Codespaces](/en/codespaces/reference/using-the-vs-code-command-palette-in-codespaces)\n\n  You can use the Command Palette feature of Visual Studio Code to access many commands in GitHub Codespaces.\n\n* [Security in GitHub Codespaces](/en/codespaces/reference/security-in-github-codespaces)\n\n  Overview of the GitHub Codespaces security architecture, with guidelines to help you maintain security and minimize the risk of attack.\n\n* [Disaster recovery for GitHub Codespaces](/en/codespaces/reference/disaster-recovery-for-github-codespaces)\n\n  This article describes guidance for a disaster recovery scenario, when a whole region experiences an outage due to major natural disaster or widespread service interruption.\n\n* [GitHub Codespaces logs](/en/codespaces/troubleshooting/github-codespaces-logs)\n\n  Overview of the logs used by GitHub Codespaces.\n\n* [Troubleshooting GitHub Codespaces clients](/en/codespaces/troubleshooting/troubleshooting-github-codespaces-clients)\n\n  This article provides troubleshooting information for issues you may encounter with the client you use for GitHub Codespaces.\n\n* [Getting the most out of your included usage](/en/codespaces/troubleshooting/troubleshooting-included-usage)\n\n  Find out about the free use of GitHub Codespaces that's included with personal accounts.\n\n* [Exporting changes to a branch](/en/codespaces/troubleshooting/exporting-changes-to-a-branch)\n\n  This article provides steps for exporting your codespace changes to a branch.\n\n* [Troubleshooting creation and deletion of codespaces](/en/codespaces/troubleshooting/troubleshooting-creation-and-deletion-of-codespaces)\n\n  This article provides troubleshooting steps for common issues you may experience when creating or deleting a codespace, including storage and configuration issues.\n\n* [Troubleshooting authentication to a repository](/en/codespaces/troubleshooting/troubleshooting-authentication-to-a-repository)\n\n  Learn how to troubleshoot common authentication issues when you clone, push to, or pull from a repository in a codespace.\n\n* [Troubleshooting your connection to GitHub Codespaces](/en/codespaces/troubleshooting/troubleshooting-your-connection-to-github-codespaces)\n\n  Troubleshooting help for connecting to GitHub Codespaces.\n\n* [Troubleshooting prebuilds](/en/codespaces/troubleshooting/troubleshooting-prebuilds)\n\n  You can use prebuilds to speed up the creation of codespaces. This article provides troubleshooting steps for common issues with prebuilds.\n\n* [Troubleshooting personalization options for GitHub Codespaces](/en/codespaces/troubleshooting/troubleshooting-personalization-for-codespaces)\n\n  Troubleshooting steps for common issues with dotfiles and Settings Sync.\n\n* [Troubleshooting port forwarding for GitHub Codespaces](/en/codespaces/troubleshooting/troubleshooting-port-forwarding-for-github-codespaces)\n\n  Troubleshooting steps for common port forwarding issues.\n\n* [Troubleshooting GPG verification for GitHub Codespaces](/en/codespaces/troubleshooting/troubleshooting-gpg-verification-for-github-codespaces)\n\n  This article provides troubleshooting advice for errors related to signing your commits in codespaces.\n\n* [Working with support for GitHub Codespaces](/en/codespaces/troubleshooting/working-with-support-for-github-codespaces)\n\n  Tips on getting the best help from support for GitHub Codespaces.\n\n* [The github.dev web-based editor](/en/codespaces/the-githubdev-web-based-editor)\n\n  You can use the github.dev web-based editor to edit files and commit your changes."}