What is Github Token and how can we create it?

Hivel Krasniqi
2 min readMay 13, 2022

--

Github Tokens are an alternative to using passwords for authentication to GitHub when using the GitHub API or the command line.

Note: It is very important to protect your token. So when you generate your token, copy and save in a private file. I am using Bitwarden to protect all my passwords.

Creating a token:

1.Verify your email address, if it hasn’t been verified yet.

2.In the upper-right corner of any page, click your profile photo, then click Settings.

3.In the left sidebar, click Developer settings.

4.In the left sidebar, click Personal access tokens.

5.Click Generate new token.

6.Give your token a descriptive name.

7.To give your token an expiration, select the Expiration drop-down menu, then click a default or use the calendar picker. (I suggest 90 days)

8.Select the scopes, or permissions, you’d like to grant this token. To use your token to access repositories from the command line, select repo. (you can select all)

9.Click Generate token.

Completed, now you can use your token in your projects.

--

--

Hivel Krasniqi

Software Automation Engineer expert, Instructor, passionate about CI/CD, Workflow Automation and Productivity