GIT: Solve “Password authentication is temporarily disabled as part of a brownout. Please use a personal access token instead”

If you were using username password for pushing your code, it was working previous but now below error happens:

Username for 'https://github.com': ...
Password for 'https://...@github.com': 
remote: Password authentication is temporarily disabled as part of a brownout. Please use a personal access token instead.
remote: Please see https://github.blog/2020-07-30-token-authentication-requirements-for-api-and-git-operations/ for more information.

The reason is that from November 13th, 2020, account passwords when authenticating with the REST API  is no longer accepted, and it requires the use of token-based authentication (e.g., a personal access, OAuth, or GitHub App installation token) for all authenticated API operations on GitHub.com.

Solution

1. Generate a new token according to below link.

https://docs.github.com/en/github/authenticating-to-github/keeping-your-account-and-data-secure/creating-a-personal-access-token

2. Update remote URL

git remote set-url origin https://[NEW_TOKEN]@github.com/[ORGANISATION]/[REPO].git

3. Git pull once

git pull https://[token]@github.com/[ORGANISATION]/[REPO].git

Congratulations! You are good to go now.