[Easy, Free Tip] Using Google Sheets to Check for Available Account Names, Expired Web 2.0s, etc.

MatthewGraham

BANNED
Joined
Oct 6, 2015
Messages
1,759
Reaction score
2,755
Saw this thread a few minutes ago and decided to write out a generalized answer: https://www.blackhatworld.com/seo/any-reddit-account-checker.1019822/

The example below is specific to Reddit. Works with slight modifications for other sites; basically all that is needed to make this work with other sites (for example if you're looking for expired web 2.0s) is to:
  • Scrape/find the list of URLs you want to check
  • Figure out what their page codes correspond to.
    • If anyone happens to know what HTTP codes go with what for other sites that this would work for and is generous enough to share, feel free to comment below. Or don't. I'm not your dad.
Anyway...

Without further ado:

1. Make a new spreadsheet in Google Sheets

2. Go to Tools --> Script Editor

3. Copy-paste this into the script editor and save it with ctrl+S
Code:
// https://medium.com/@the.benhawy/how-to-use-google-spreadsheets-to-check-for-broken-links-1bb0b35c8525
function getStatusCode(url){
   var options = {
     'muteHttpExceptions': true,
     'followRedirects': true
   };
   var response = UrlFetchApp.fetch(url, options);
   return response.getResponseCode();
}

4. Put the full list of usernames in column A. List them as the full URL to the user's profile (https://www.reddit.com/user/some_username_816)

5. In column B1, enter this formula: =getStatusCode(A1)

6.
Drag the formula down so that it checks all the URLs

7. The script will check the page code of the user pages. These are what they correspond to (for Reddit accounts):
  • 404 = Account doesn't exist and is available to be registered
    • Note: Shadowbanned accounts also show up as 404 as well and are not available for registration. There's probably a more accurate way to determine this; shadowbans are rare enough that it basically doesn't matter.
  • 403 = Account has been banned (not available)
  • 200 = Account is active and in use (not available)
 
Does it still work ?
 
Doesn't work - it shows all urls as 200 even though half the accs are banned..
 
Back
Top