ity features  ](/en/actions/security-guides/using-githubs-security-features-to-secure-your-use-of-github-actions)
    * [ Automatic token authentication  ](/en/actions/security-guides/automatic-token-authentication)

  * Creating actions 

    * [ About custom actions  ](/en/actions/creating-actions/about-custom-actions)
    * [ Create a Docker container action  ](/en/actions/creating-actions/creating-a-docker-container-action)
    * [ Create a JavaScript action  ](/en/actions/creating-actions/creating-a-javascript-action)
    * [ Create a composite action  ](/en/actions/creating-actions/creating-a-composite-action)
    * [ Metadata syntax  ](/en/actions/creating-actions/metadata-syntax-for-github-actions)
    * [ Dockerfile support  ](/en/actions/creating-actions/dockerfile-support-for-github-actions)
    * [ Set exit codes  ](/en/actions/creating-actions/setting-exit-codes-for-actions)
    * [ Publish in GitHub Marketplace  ](/en/actions/creating-actions/publishing-actions-in-github-marketplace)
    * [ Share from your private repository  ](/en/actions/creating-actions/sharing-actions-and-workflows-from-your-private-repository)
    * [ Share with your organization  ](/en/actions/creating-actions/sharing-actions-and-workflows-with-your-organization)
    * [ Release and maintain actions  ](/en/actions/creating-actions/releasing-and-maintaining-actions)
    * [ CLI setup action  ](/en/actions/creating-actions/developing-a-third-party-cli-action)

  * [ Guides for GitHub Actions  ](/en/actions/guides)

  * [ GitHub Actions ](/en/actions "GitHub Actions") / 
  * [ Using jobs ](/en/actions/using-jobs "Using jobs") / 
  * [ Assign permissions to jobs ](/en/actions/using-jobs/assigning-permissions-to-jobs "Assign permissions to jobs")

#  Assigning permissions to jobs

Modify the default permissions granted to ` GITHUB_TOKEN ` .

##  In this article

  * Overview 
  * Defining access for the GITHUB_TOKEN scopes 
  * Setting the GITHUB_TOKEN permissions for all jobs in a workflow 
  * Setting the GITHUB_TOKEN permissions for a specific job 

##  Overview

You can use ` permissions ` to modify the default permissions granted to the `
GITHUB_TOKEN ` , adding or removing access as required, so that you only allow
the minimum required access. For more information, see " [ Automatic token
authentication ](/en/actions/security-guides/automatic-token-
authentication#permissions-for-the-github_token) ."

You can use ` permissions ` either as a top-level key, to apply to all jobs in
the workflow, or within specific jobs. When you add the ` permissions ` key
within a specific job, all actions and run commands within that job that use
the ` GITHUB_TOKEN ` gain the access rights you specify. For more information,
see [ ` jobs.<job_id>.permissions ` ](/en/actions/using-workflows/workflow-
syntax-for-github-actions#jobsjob_idpermissions) .

For each of the available scopes, shown in the table below, you can assign one
of the permissions: ` read ` , ` write ` , or ` none ` . If you specify the
access for any of these scopes, all of those that are not specified are set to
` none ` .

Available scopes and details of what each allows an action to do:

Scope  |  Allows an action using ` GITHUB_TOKEN ` to   
---|---  
` actions ` |  Work with GitHub Actions. For example, ` actions: write ` permits an action to cancel a workflow run. For more information, see " [ Permissions required for GitHub Apps ](/en/rest/overview/permissions-required-for-github-apps?apiVersion=2022-11-28#repository-permissions-for-actions) ."   
` checks ` |  Work with check runs and check suites. For example, ` checks: write ` permits an action to create a check run. For more information, see " [ Permissions required for GitHub Apps ](/en/rest/overview/permissions-required-for-github-apps?apiVersion=2022-11-28#repository-permissions-for-checks) ."   
` contents ` |  Work with the contents of the repository. For example, ` contents: read ` permits an action to list the commits, and