LinkedIn Profile Scraper

Collects valuable information you need from LinkedIn profiles

Share:  
Table of Contents

Export info from LinkedIn profiles

When building your CRM, you sometimes need to gather information from LinkedIn contacts/prospects. Don't waste your time copy/pasting anymore. Retrieve all the data you need of the specific LinkedIn profiles you're targeting in a CSV file.

Our Solution

Launch an automated agent that will connect on LinkedIn as you. It will then browse and collect all the info from the designated profiles.

Caution

  1. As the agent will connect to your account, use this script sparingly. LinkedIn only allows you to view a certain number of profiles per day/month. Consider this when launching the agent or it might get your account slowed down.
    More infos about >> LinkedIn Commercial Use Limit <<
  2. We've noticed that without LinkedIn Premium, you can only scrape 100 profiles in one go. Your mileage may vary.

What will you need? ⚙️

  • Session cookie: Your session cookie from LinkedIn.
  • Spreadsheet URL: The link of a Google Spreadsheet with LinkedIn profile URLs in it.

(You already have all that? Click straight away on "Use this API")

Which data will you collect?

IN CSV

  1. LinkedIn profil link

  2. Description

  3. First name

  4. Last name

  5. Full name

  6. N° of subscribers

  7. Company name

  8. Current job title

  9. Description of the current job

  10. Location of that job

  11. Mail (if available)

  12. Phone number (if available)

  13. Twitter (if available)

  14. Skill 1

  15. Skill 2

  16. Skill 3

IN JSON

In addition to everything listed above:

  1. Profile image URL

  2. Headline

  3. Connections

  4. Description field

  5. Following infos from all listed Job

  • Company name
  • Company URL
  • Job title
  • Date range
  • Location
  • Description
  1. Following infos from all listed education
  • School name
  • School URL
  • Degree
  • Degree specifications
  • Date range
  • Description
  1. Website (if available)
  2. Number of endorsements for each of the 3 skills

Which steps to follow?

1. Create an account on Phantombuster.com 💻

If you haven't already, create a FREE account on Phantombuster. Our service will browse the web for you. It’s a website automator which runs in the cloud. Once done we'll follow up.

2. Use this API on your account.👌

Now that you're connected to Phantombuster, Click on the following button (it will open a new tab).

3. Click on Configure me!

You'll now see the 3 configuration dots blinking. Click on them.

4. Linkedin authentication 🔑

Because the script will manipulate LinkedIn for you, it needs to be logged on your LinkedIn account. For that you just need to copy paste your session cookie in the script argument:

  • Using Chrome, go to your LinkedIn homepage and open the inspector
    → Right click anywhere on the page and select “Inspect”
    CMD+OPT+i on macOS
    or
    F12 or CTRL+MAJ+i on Windows

  • Locate the “Application” tab

  • Select “Cookies” > “http://www.linkedin.com” on the left menu.

  • Locate the “li_at” cookie.

  • Copy what’s under “Value” (Double click on it then Ctrl+C) and paste it into your script Argument)

// How to access your cookies with Firefox and Safari//

5. Add a Google Spreadsheet 📑

Below your session cookie you’ll find spreadsheetUrl

Enter in the text field a link of a Google Spreadsheet with this same format (only column A is mandatory):

Add every linkedIn profiles link in column A (one link per row)

Please make sure your file is publicly accessible!

You can also enter a CSV file URL, it will work the same :)

Click on Launch & Enjoy!

It’s done! All that is left to do is to click on "launch" to try your script!

This will launch the bot and, if you didn't already change the spreadsheet URL, will collect the information of the Phantombuster team.

⚙ ️HTTP API 🤓

If you want to use this API programmatically you can replace the argument spreadsheetUrl by profileUrls which must be an array of strings.

It should look just like this :
"profileUrls": ["www.linkedin.com/in/foo", "www.linkedin.com/in/bar"]

Limits

Please be aware that this API, like most of our LinkedIn APIs, will manipulate your own account on your behalf. Like Uncle Ben once said, "With great power comes great responsibility."

We have noticed that visiting more than 80 connections per day will almost always result in LinkedIn invalidating your session cookie (that is, logging you out). We recommend no more than one launch per day of 80 scraped profiles for this reason.

Having a LinkedIn Premium subscription might raise this limit. Please see these official LinkedIn help pages: Commercial Use Limit and Finding People on LinkedIn.

Output

This API will output CSV and/or JSON containing the following fields:

  • linkedinProfile (LinkedIn profile URL)
  • description (LinkedIn profile description)
  • firstName
  • lastName
  • fullName
  • subscribers (How many subscribers does she/he have)
  • company (What is the name of the company she/he is currently working for)
  • companyUrl (What is the url of the company she/he is currently working for)
  • jobTitle (What is her/his current job title)
  • jobDescription (Description of the current job)
  • location (Where is she/he located)
  • mail (what is her/his professionnal email address)
  • phoneNumber
  • twitter
  • skill1 (Skill set as her/his 1st one)
  • skill2 (Skill set as her/his 2nd one)
  • skill3 (Skill set as her/his 3rd one)

Developers

Like all APIs on Phantombuster, this API comes with an HTTP endpoint. Launch it from your computer, app or server with a simple HTTP request and get its result as JSON. Click Use this API above to create your new endpoint.

Clone this API

The script below is all that's required to make the API work. If you're a developer, click the button to clone the code into a new Custom API Agent in your Phantombuster account. This operation will allow you to customize the API to your exact needs. This will also create a custom HTTP endpoint.

Contribute on GitHub

Feeling adventurous? Unsatisfied with the current state of this API? Send us pull requests on GitHub to improve the API store! The script is here and you might be interested in reading our documentation here .

(we reward contributions we like with free Phantombuster accounts :D)

Share this API

Your friends & colleagues need to know about this!