Simple Lead Scoring and Qualification in Salesforce

Simple Lead Scoring and Qualification in Salesforce

March 10, 2017

This article is specifically for the Salesforce users out there. For a more general overview on lead qualification, see the modern guide to lead qualification.

Salesforce is an ideal place to do lead qualification and scoring as it is typically the system of record and where all lead, contact, and account information lives. Building a lead scoring process in Salesforce offers two key benefits:

  1. Enriched data with demographic attributes can be easily added.
  2. All recorded sales activity can be used within your scoring formulas.

It's important to note you don't have to include all of your data in your lead scoring. It is often best to start with a basic lead scoring model and then build over time as you define your ideal customer profile (ICP) and understand what activities predict conversions.

When starting, demographic and firmographic data can form the base of your model. Who your lead is (and what company they work for), is very often more important than what actions they are taking on your site or within your app. This seems to be especially true in the B2B SAAS market.

The first step to scoring leads is to get that data into your Salesforce instance. Using the Clearbit Salesforce Integration, or something like, you can append all relevant personal, social, and company information to each and every record you have in Salesforce.


Clearbit data inside Salesforce: All enrichment fields are available for any Salesforce record

From there, you can start building out your scoring rules based on your new rich standardized data set.

Below, we've put together a quick tutorial to get you started using just a custom field and a bit of Apex to build a real-time custom lead score field on every lead in SFDC.

Lead qualification isn't particularly difficult, but it is extremely important to get right. When you aren't effectively (and automatically) qualifying leads as a part of your sales process, you are simply wasting time and money.

Simple lead qualification and scoring is easy to set up with Clearbit and Salesforce. Doing so will take you five minutes, but save you hours. It will also boost the quality of leads sent to your sales reps, and make sure you are only talking to the right leads for your business.

Building your own custom lead score in Salesforce.


  1. Salesforce permissions to create custom formula fields
  2. Clearbit for Salesforce installed

Step 1: Create a custom formula field on the lead object


Choose Formula under Data Type.

formula data type

Name your new Custom Field and set Formula Return Type to Percent and Decimal Places to 2.


Step 2: Paste in this pre-built Apex code.

CASE(cbit__Clearbit__r.cbit__CompanyTags__c, "B2B", 5,0)
CASE(cbit__Clearbit__r.cbit__CompanyType__c, "public", 5,0)
CASE( cbit__Clearbit__r.cbit__CompanyGeoCountryCode__c , "US", 10, 0)
CASE( cbit__Clearbit__r.cbit__CompanyMetricsEmployeesRange__c, "1000+", 7, "251-1000", 8, "51-250", 10, "11-50", 4, "1-10", 2, 0)
IF(CONTAINS( cbit__Clearbit__r.cbit__CompanyTech__c , "salesforce"), 10,
IF(CONTAINS( cbit__Clearbit__r.cbit__CompanyTech__c , "marketo"), 8,
IF(CONTAINS( cbit__Clearbit__r.cbit__CompanyTech__c , "google_analytics"), 6,0)))

Step 3: Modify fields and scores to match your own requirements.

Don't forget to change the final number to reflect the total potential sum if each criteria returns the max value. For example, in the default code above, the maximum possible value is 40.

Pro Tip: Custom fields in Salesforce tend to have names that can get quite long and unwieldy, so don't forget to use the Insert Field button above the formula edit box to search through available fields and add them to the formula with a single click.


Step 4: See it in action!

simple leadscoring in action

That's it! You now have a simple and robust lead scoring system directly within Salesforce, which you can use for lead routing, prioritization, and reporting.

Next step: Try incorporating other attributes like lead source, or sales activity into your model.

Revving up your speed to lead

Salesby Janet Choi on November 23, 2022

Mastering speed to lead for B2B starts with a well-designed system. Learn why speed closes leads, what's getting in your way, and how to rev up the buying experience.

How to automate lead routing to improve speed to lead

Salesby Janet Choi on November 03, 2022

Automating your lead routing system can reduce your response time by cutting out manual research and matching leads to the right sales rep.

Join our newsletter

Engaging stories and exclusive data, designed for our best customers. One useful issue each month.