Find Geolocation of the IP addresses via Google Apps Script

I was challenged to find Geolocation of list of IP addresses lately. I know there are plenty of online resources to find the location of an IP one by one. However, it was difficult to find a bulk approach. Hence I thought to automate the process and share with you all.

Here I used IPSTACK which offers one of the leading IP to geolocation
APIs and global IP database services worldwide.

I have a google sheet as below;

IPFinder

I’m going to paste all my IP addresses in column A and click on IP finder menu item and press process. The result will be displayed in next tab as below;

IPFinder Result

Here is the link to the document. You may try yourself.

https://goo.gl/1qaMzh

To run it on your own sheet, create below function in your Google Apps Script Editor. Make sure your sheet looks like above in my sample.

Hope you find it useful. Contact me if you need further improvements and changes.

Cheers!

Advertisements

How to find your Google Drive folder ID

This is very simple, all you want to know is Folder Name.

Imagine, I have a folder in my Google Drive as “Developments”, I need to find the folder ID.

There are two approaches,

  1. Manual method (Which is I like the most)

Go to your folder, check folder URL, copy folder id 🙂

drive

2. Script method

All you want to do is call this function;

var your_folder_id = getFolderID(“Developments”);

Cheers!