New: Expanded Property Intelligence: get detailed property data from a single API call.Learn more →
AddressVerify.io
DocsFree ToolsBlogPricingIntegrationsStatusFAQContact
Sign InGet API Key
Blog/How to Filter PO Boxes and Non-Residential Addresses From Your Leads
Lead Quality/July 7, 2026/7 min read

How to Filter PO Boxes and Non-Residential Addresses From Your Leads

By David Acimovic

If you run direct mail, home-services outreach, or any campaign that targets homeowners, learning how to filter PO boxes and non-residential addresses from your leads is one of the fastest ways to cut wasted spend. A list that looks clean can still be full of PO boxes, offices, and vacant lots that will never convert. Standard address validation will not catch them, because a PO box is a perfectly deliverable address. You need to know the property behind the address, and that takes one API call per record.

Why "valid" is not the same as "residential"

Most validation tools answer a postal question: can mail be delivered here. A PO box passes that test. So does a UPS Store mailbox, a corporate office, and a registered-agent suite. If your product or service is sold to people at home, those records are noise. Worse, they look identical to good leads in a spreadsheet, so they quietly drain your budget campaign after campaign. We wrote more about the gap between deliverability and property data in USPS Web Tools API alternatives.

The fix is to ask a different question. Instead of "is this deliverable," ask "is there a home here, and what kind." AddressVerify answers both in a single response. A residential address comes back with a homeType from a known set of classes. PO boxes, commercial receivers, and empty lots do not read as a dwelling, so they are easy to drop.

The signal: addressValid plus homeType

Every lookup returns two fields you care about here. addressValid tells you the address resolved at all. homeType tells you the kind of dwelling, one of seven classes: SINGLE_FAMILY, APARTMENT, CONDO, TOWNHOUSE, MULTI_FAMILY, MANUFACTURED, and LOT. The first six are places people live. LOT is vacant land. To keep only real residences, keep records where addressValid is true and homeType is one of those six dwelling types.

A script that cleans a list

Here is the whole idea in Node. It takes a list of raw addresses, calls the API for each one, and splits them into a residential list you keep and a rejected list you can inspect. It uses the built-in fetch in Node 18 and later, so there is nothing to install.

javascript
const API_KEY = process.env.ADDRESSVERIFY_API_KEY;

const RESIDENTIAL = new Set([
  'SINGLE_FAMILY', 'APARTMENT', 'CONDO',
  'TOWNHOUSE', 'MULTI_FAMILY', 'MANUFACTURED',
]);

async function lookup(address) {
  const res = await fetch('https://api.addressverify.io/service/lookup/address', {
    method: 'POST',
    headers: {
      'x-api-key': API_KEY,
      'Content-Type': 'application/json',
    },
    body: JSON.stringify({ address }),
  });
  return res.json();
}

async function cleanList(addresses) {
  const kept = [];
  const rejected = [];

  for (const address of addresses) {
    const result = await lookup(address);
    if (result.addressValid && RESIDENTIAL.has(result.homeType)) {
      kept.push({ address, homeType: result.homeType });
    } else {
      rejected.push({ address, reason: result.homeType || 'not residential' });
    }
  }

  return { kept, rejected };
}

const leads = [
  '1013 Bates Ave, Bakersfield, CA 93307',
  'PO Box 1234, Bakersfield, CA 93301',
  '5000 California Ave Suite 300, Bakersfield, CA 93309',
];

cleanList(leads).then(({ kept, rejected }) => {
  console.log('Keep:', kept);
  console.log('Drop:', rejected);
});

Running that over the sample list keeps the house, drops the PO box, and drops the office suite, with a reason attached to each rejection so you can spot-check the logic:

text
Keep: [ { address: '1013 Bates Ave, Bakersfield, CA 93307', homeType: 'SINGLE_FAMILY' } ]
Drop: [
  { address: 'PO Box 1234, Bakersfield, CA 93301', reason: 'not residential' },
  { address: '5000 California Ave Suite 300, Bakersfield, CA 93309', reason: 'not residential' }
]

The same thing in Python

If your pipeline is in Python, the shape is identical. This version reads a CSV with an address column and writes a filtered CSV.

python
import csv
import os
import requests

API_KEY = os.environ['ADDRESSVERIFY_API_KEY']

RESIDENTIAL = {
    'SINGLE_FAMILY', 'APARTMENT', 'CONDO',
    'TOWNHOUSE', 'MULTI_FAMILY', 'MANUFACTURED',
}

def lookup(address):
    res = requests.post(
        'https://api.addressverify.io/service/lookup/address',
        headers={'x-api-key': API_KEY, 'Content-Type': 'application/json'},
        json={'address': address},
    )
    return res.json()

with open('leads.csv') as infile, open('residential.csv', 'w', newline='') as outfile:
    reader = csv.DictReader(infile)
    writer = csv.writer(outfile)
    writer.writerow(['address', 'homeType'])

    for row in reader:
        result = lookup(row['address'])
        if result.get('addressValid') and result.get('homeType') in RESIDENTIAL:
            writer.writerow([row['address'], result['homeType']])

Notes for production

  • Keep your rejects. Do not delete dropped rows. Store the reason so you can audit the filter and tune it to your definition of a good lead. Some campaigns want MULTI_FAMILY in, others want it out.
  • Mind the rate limits. The free tier allows 50 calls a month at one call per second, which is plenty for testing. For a real list, use a plan with the throughput you need and add a small delay or a concurrency limit so you stay under your calls-per-second cap. See pricing for the tiers.
  • Cache results. The same address will show up across many lists. Store lookups so you never pay for the same record twice.
  • Want more than a keep or drop decision? Add ?expanded=true to pull beds, baths, and value, and score leads instead of just filtering them.

Try it on a real address

You can see the classification for any single address in the free address verifier tool before you write a line of code. When you are ready to wire it in, the API docs cover every field. And if you want to understand exactly what each homeType means, read how to classify property type from an address. And for how common bad addresses actually are, see The State of Address Data, our analysis of 500,000 real lookups.

Try it on your own addresses

The AddressVerify free tier includes 50 API calls a month, no credit card required. Validate an address, classify the property type, and get an estimated value in one call.

Start freeRead the API docs

Related guides

  • USPS Web Tools API Alternatives for Address Validation
  • How to Classify Property Type From an Address (API Guide)
AddressVerify.io

The most accurate residential address verification API for businesses.

G25.0Read our reviews on G2 →

Product

  • Pricing
  • API Docs
  • Integrations
  • FAQ
  • Status

Resources

  • Free Address Verifier
  • Blog
  • Compare APIs
  • AddressVerify vs Smarty
  • AddressVerify vs Melissa

Support

  • Contact Support

© 2026 AddressVerify.io. All rights reserved.

Privacy PolicyTerms of Service
Developed by Growth Key