LRN lookup API

LRN lookup API: routing number and porting status for US and Canadian numbers

An LRN (Local Routing Number) is the 10-digit number that identifies the switch serving a phone number. When a number is ported to another carrier, calls and texts are routed on its LRN, not on its own digits. The CheckThatPhone LRN lookup API returns that routing number for any US or Canadian number as dipLrn, together with dipPorted, dipOcn, dipCarrier, dipCarrierType and dipCarrierSubType, from a live carrier dip at lookup time.

The FCC's number portability orders call it the location routing number: each central office switch is assigned a unique 10-digit number that "serves as a network address" for routing (FCC 97-289, para. 8). Number portability itself is the ability to keep your number when you switch carriers at the same location (47 CFR 52.21). One POST /v1/lookup call costs one credit, and the Free plan includes 500 lookups a month.

Want the carrier name for display, filtering or line type? The carrier lookup API page covers which carrier serves a number. This page is about the routing side of the same lookup: the LRN, the ported flag and the OCN.

Fields an LRN lookup returns

A lookup returns these routing fields. Values are strings, including booleans.

FieldExampleMeaning
dip "success" Status of the live carrier dip: "success", "error" or "invalid". Read the fields below only when it is "success"; otherwise they can be missing.
dipLrn "4695550198" Local Routing Number: the number actually used for call and SMS routing. For a number that hasn't been ported it matches the number itself.
dipPorted "true" "true" when dipLrn differs from the number, the standard industry method for detecting that a number has moved to a different carrier than it was originally assigned to.
dipOcn "6529" Operating Company Number: the code that identifies the carrier currently operating the number.
dipCarrier "T-Mobile" Name of the carrier serving the number now, from the live carrier dip.
dipCarrierType "mobile" Broad carrier type: "mobile", "landline", "invalid" or "undefined".
dipCarrierSubType "PCS" Sub-classification such as WIRELESS or PCS (mobile), ILEC, RBOC or CLEC (wireline) and IPES (VoIP). The docs list every code.

Ported vs original carrier

Phone numbers are handed to carriers in blocks, by area code and prefix (the NPA-NXX). A prefix table can tell you which carrier a block was assigned to, and an area code tells you where the number was issued: see the area code directory. Neither tells you who serves the number today. When a subscriber ports, the number keeps its area code and prefix and moves to a new carrier, so any answer built on the digits alone still points at the original block holder.

The live carrier dip reads current routing data instead. For a ported number, dipLrn holds the routing number of the new carrier's switch, dipPorted is "true", and dipCarrier and dipOcn name the carrier the number moved to. The numbering-plan view is in nanpCarrier, which the docs flag as not authoritative after a port: prefer dipCarrier. The carrier lookup API page goes deeper on the carrier fields.

Example request and response

Send the number in any common format.

curl --request POST \
  --url 'https://api.checkthatphone.com/v1/lookup' \
  --header 'Authorization: Bearer YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{"phone": "469-555-0163"}'

An illustrative response for a ported mobile number (a fictional 555 number; field names and formats match the live API). dipLrn differs from subscriber, so dipPorted is "true":

{
  "success": true,
  "credits_used": 1,
  "data": {
    "subscriber": "4695550163",
    "optDate": "2026-10-08T16:21:09.514Z",
    "action": "send",
    "deliverable": "true",
    "nanpType": "mobile",
    "blackList": "false",
    "dip": "success",
    "dipLrn": "4695550198",
    "dipPorted": "true",
    "dipOcn": "6529",
    "dipCarrierSubType": "PCS",
    "dipCarrier": "T-Mobile",
    "dipCarrierType": "mobile",
    "geoState": "TX",
    "geoCity": "dallas",
    "geoCountry": "US",
    "timezone": "America/Chicago",
    "tzOffset": 6,
    "geoSource": "area-code",
    "error": "false",
    "smsEligible": "true"
  }
}

credits_used: 1 is the whole cost of this call. The same fields come back from the official Node.js and Python SDKs and in every row of a bulk CSV upload.

What teams use LRN and porting data for

Limits worth knowing

Pricing

LRN and porting data are part of every lookup: one credit, no separate fee. The Free plan has 500 lookups a month, hard-capped. Paid plans are $5 for 1,000, $30 for 10,000, $100 for 100,000 and $450 for 500,000 lookups a month, with overage from $0.005 down to $0.0009 per lookup. Failed lookups are free. See pricing.

LRN lookup: common questions

What is an LRN lookup?

A query, sometimes called a number portability lookup, that returns the Local Routing Number (LRN) for a phone number: the 10-digit number of the switch that serves it, which is what calls and texts to a ported number are routed on. A CheckThatPhone lookup returns it as dipLrn, together with dipPorted, dipOcn, dipCarrier, dipCarrierType and dipCarrierSubType, from a live carrier dip.

How do I know if a number has been ported?

Read dipPorted. It is "true" when dipLrn differs from the number itself, the standard way to detect a port, and dipCarrier and dipOcn then name the carrier the number moved to. Values are strings, so compare against "true", not a boolean.

Does the LRN lookup work for Canadian numbers?

Yes. The API accepts US and Canadian (NANP) numbers in any common format: 10 digits, or 11 digits starting with 1. Every lookup runs the same live carrier dip. Numbers outside North America are not supported.

Does it show when a number was ported, or whether its SIM was swapped?

No. A lookup returns the current state only: today's routing number, carrier and ported flag. There is no porting date, no port history and no SIM-swap signal. A SIM swap usually keeps the number on the same carrier, so carrier data doesn't change.

What is the difference between dipLrn and dipOcn?

dipLrn is a routing number: the 10-digit address of the switch that serves the number. dipOcn is the Operating Company Number, the code that identifies the carrier operating the number. Use the first for routing and the second for carrier-level rules.

How much does an LRN lookup cost?

One credit, and the same call also returns line type, deliverability and location. The Free plan includes 500 lookups a month, hard-capped; paid plans start at $5 a month for 1,000 lookups. Failed lookups are not billed. See pricing.

Related

Try it on your list

Free tier: 500 lookups per month, hard-capped. Paid plans start at $5/month.