Connect your GitHub account

Connecting GitHub to your Streamlit Community Cloud account allows you to deploy apps directly from the files you store in your repositories. It also lets the system check for updates to those files and automatically update your apps. When you first connect your GitHub account to your Community Cloud account, you'll be able to deploy apps from your public repositories to Community Cloud. If you want to deploy from private repositories, you can give Community Cloud additional permissions to do so. For more information about these permissions, see GitHub OAuth scope.

priority_high

Important

In order to deploy an app, you must have admin permissions to its repository. If you don't have admin access, contact the repository's owner or fork the repository to create your own copy. For more help, see our community forum.

If you are a member of a GitHub organization, that organization is displayed at the bottom of each GitHub OAuth prompt. In this case, we recommend reading about Organization access at the end of this page before performing the steps to connect your GitHub account. You must be an organization's owner in GitHub to grant access to that organization.

  • You must have a Community Cloud account. See Create your account.
  • You must have a GitHub account.
  1. In the upper-left corner, click "Workspaces warning."
Connect your GitHub account to a new Community Cloud account
  1. From the drop down, click "Connect GitHub account."

  2. Enter your GitHub credentials and follow GitHub's authentication prompts.

  3. Click "Authorize streamlit."

    Authorize Community Cloud to connect to your GitHub account

    This adds the "Streamlit" OAuth application to your GitHub account. This allows Community Cloud to work with your public repositories and create codespaces for you. In the next section, you can allow Community Cloud to access your private repositories, too. For more information about using and reviewing the OAuth applications on your account, see Using OAuth apps in GitHub's docs.

After your Community Cloud account has access to deploy from your public repositories, you can follow these additional steps to grant access to your private repositories.

  1. In the upper-left corner, click on your GitHub username.
Access your workspace settings
  1. From the drop down, click "Settings."
  2. On the left side of the dialog, select "Linked accounts."
  3. Under "Source control," click "Connect here arrow_forward."
  4. Click "Authorize streamlit."
Authorize Community Cloud to connect to your private GitHub repositories

To deploy apps from repositories owned by a GitHub organization, Community Cloud must have permission to access the organization's repositories. If you are a member of a GitHub organization when you connect your GitHub account, your OAuth prompts will include a section labeled "Organization access."

GitHub Oauth prompt including organization access

If you have already connected your GitHub account and need to add access to an organization, follow the steps in Manage your GitHub connection to disconnect your GitHub account and start over. Alternatively, if you are not the owner of an organization, you can ask the owner to create a Community Cloud account for themselves and add permission directly.

For any organization you own, if authorization has not been previously granted or denied, you can click "Grant" before you click "Authorize streamlit."

Authorize your Streamlit on a GitHub organization you own

For an organization you don't own, if authorization has not been previously granted or denied, you can click "Request" before you click "Authorize streamlit."

Authorize your Streamlit on a GitHub organization owned by others

If someone has already started the process of authorizing Streamlit for your organization, the OAuth prompt will show the current status.

Approved access

If an organization has already granted Streamlit access, the OAuth prompt shows a green check (check).

Approved authorization for Streamlit on an organization

Pending access

If a request has been previously sent but not yet approved, the OAuth prompt show "Access request pending." Follow up with the organization's owner to accept the request in GitHub.

Pending authorization for Streamlit on an organization

Denied access

If a request has been previously sent and denied, the OAuth prompt shows a red X (close). In this case, the organization owner will need to authorize Streamlit from GitHub. See GitHub's documentation on OAuth apps and organizations.

Denied authorization for Streamlit on an organization

Now that you have your account you can Explore your workspace. Or if you're ready to go, jump right in and Deploy your app.

forum

Still have questions?

Our forums are full of helpful information and Streamlit experts.