Skip to content
Find and fetch user information with GitHub's API using plain javascript
JavaScript CSS
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Find and Fetch user information with GitHub's API using plain javascript, only by entering a username.

Running the Project Locally

Clone the repository to your local machine:

git clone


First you must create an application, all you need to worry about for now is the url's. I personally used for the site and webhook url (it's up to you).

More detailed explanation of the application url:

Homepage URL User authorization callback URL Webhook URL

Once the application is created, you are provided with client id and client secret token which you then need to apply to your app.js file

const client_id = "your_token";
const client_secret = "your_token";

Install live-server

Get the server up and running (-g stands for global)

npm install live-server -g

To run the server


Using GitHub's API

To use GitHub's API, you obviously need to fetch the API from GitHub. (URL is continuous)

const fetchUser = async (user) => {
    const api_call = await fetch(`${user}?client_id=$

A small part of GitHub's JSON code as an example

  "login": "endormi",
  "url": "",
  "html_url": "",
  "followers_url": "",
  "following_url": "{/other_user}",
  "gists_url": "{/gist_id}",
  "repos_url": "",

ONLY For Public Repositories


The source code is released under the MIT License.

You can’t perform that action at this time.