An MNP lookup tells you which mobile network a number belongs to today, after any porting, so each SMS can be routed to the operator that actually serves it. Combined with an HLR check for reachability, it lets you clean lists and stop paying for messages that were never going to land.
This guide explains why ported numbers break prefix-based routing, how MNP lookup differs from HLR, how to call the HLR and MNP lookup API, and where the savings come from.
What is mobile number portability, and why does it break prefix routing?
Mobile number portability lets people keep their number when they switch operator. In the EU it is a legal right: under the European Electronic Communications Code, users with numbers from the national numbering plan can keep them regardless of provider, and a ported number must be activated within one working day of the agreed date (Directive (EU) 2018/1972, Article 106). Switching is quick for users, so it happens often.
For senders, the consequence is simple: the prefix no longer tells you the network. A number range is allocated to one operator, the number range holder, but any number in it may now be served by another. Regulators and operators use three terms for this (CEPT ECC Report 155):
- Donor network: the operator the number is leaving
- Recipient network: the operator that now serves the number
- Number range holder: the operator the number block was originally allocated to
Many European countries keep a central reference database of ported numbers that operators synchronise with and query to route traffic directly to the recipient. Others rely on onward routing, where traffic goes to the range holder first and is passed on. An MNP lookup queries this portability data for you, so your routing does not depend on prefix tables that go out of date the day a user switches.
How do ported numbers affect SMS delivery and cost?
Application-to-person SMS is routed per destination network, identified by its MCC and MNC. When a platform decides the network from the prefix alone, a ported number is treated as a subscriber of the donor network. That causes three kinds of problem:
- Wrong route. The message goes to a route built for the donor network, which may forward it, delay it or drop it depending on local arrangements.
- Wrong price. In many markets, termination rates differ between networks, so a prefix guess can mean paying one network’s rate for a message that another network delivers.
- Wrong rules. Sender ID registration, content filtering and template rules can differ by network. A campaign set up for one operator can be filtered by another.
The effect also shows up in your data. Delivery reports and per-network statistics point at the wrong operator, which makes routing problems much harder to diagnose.
What is the difference between MNP, HLR and carrier lookup?
| Check | What it answers | Data source | Best for |
|---|---|---|---|
| MNP lookup | Which network serves this number now? | Portability data | Routing and pricing in port-heavy markets, segmenting lists by network |
| HLR lookup | Is the line active and reachable, and on which network? | A live query to the home network | Removing dead numbers, checking reachability before important sends |
| Carrier lookup (MCC-MNC mapping) | Which network was this number range allocated to? | Static numbering data | Formatting, quick routing rules, a fallback when live data is not needed |
A good rule: use HLR for health and reachability, add MNP where porting is common, and keep a static MCC-MNC mapping for formatting and simple rules.
How do you run an MNP lookup with the SMS.to API?
A single lookup is synchronous, which suits signup forms and checks just before sending an OTP:
curl -X POST https://mnp.sms.to/api/v2/lookup \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "number": "+447700900123" }'
If numbers are stored without a country code, add default_prefix with a two-letter ISO country code, and the API will apply it to any number not in international format. For a list, send an array. Batch lookups run asynchronously and return a report_id:
curl -X POST https://mnp.sms.to/api/v2/lookup \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "numbers": ["+447700900123", "+447700900456", "+447700900789"] }'
# Then fetch the results using the report_id from the response (12345 here)
curl https://mnp.sms.to/api/v2/reports/12345 \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Accept: application/json"
To see what a job will cost before running it, send the same body to POST https://mnp.sms.to/api/v2/estimate. Reports can be listed and sorted by totals such as invalid, rejected, duplicates and cost, which makes it easy to spot a bad import. Lookups can also be run from the dashboard with CSV upload where enabled, and results exported. Full details are in the API documentation.
The response gives you routing data such as whether the number is ported, the operator name, MCC and MNC, the country and the number type. Fields vary by country and operator, so confirm coverage for any field your logic depends on.
How does an MNP lookup cut wasted SMS spend?
Savings come from four places:
- Fewer sends to bad entries. Batch reports flag invalid numbers and duplicates, which you should never pay to message.
- No SMS to landlines. The number type shows fixed lines that cannot receive SMS.
- Correct routing. Messages go to the network that serves the number, so fewer fail or stall on the wrong route.
- Cleaner reporting. Per-network delivery data becomes reliable, so you can fix real routing problems instead of chasing false ones.
The maths is easy to run on your own list. Suppose a 200,000-number list contains 8,000 invalid or duplicate entries. Each campaign to that list pays for 8,000 messages that cannot be delivered, before any other failures are counted. A lookup is paid for once, while the waste repeats with every send. Multiply those 8,000 entries by your average SMS price and the number of campaigns a year, and compare it with the estimate endpoint’s figure for the list.
To catch numbers that are valid but no longer in use, add an HLR lookup, which checks live status on the network. MNP tells you where a number lives; HLR tells you whether anyone is home.
When should you run MNP lookups?
- At collection: check each number when it is entered at signup or checkout, alongside basic format validation to E.164.
- Before large campaigns: run a batch on the full list and suppress invalid and duplicate entries.
- On a schedule: recheck older segments every few months, because users keep switching networks.
- Before sensitive OTPs: porting is one of the risk signals NIST lists for SMS codes. Our guide to SMS 2FA security explains how to use it.
For verification flows, a clean number also makes channel fallback more predictable; see our guide to OTP flows with smart fallback.
How SMS.to handles MNP and HLR lookups
SMS.to offers HLR and MNP lookups through the same account you send from, with single and batch lookups over the API, dashboard lookups with export, and cost estimates before you run a job. The results feed straight into routing and list hygiene for your SMS campaigns and Verify flows. You can start with a free trial, and the team can arrange evaluation credits or volume pricing for larger lists. SMS.to is operated by Intergo Telecom, a licensed telecom and CPaaS operator.
FAQs
What is the difference between an MNP lookup and an HLR lookup?
An MNP lookup tells you which network currently serves a number, after any porting. An HLR lookup queries the live network for the number’s status, such as whether the line is active and reachable. Use MNP for routing and HLR for reachability.
Does an MNP lookup tell me if a number is active?
Not reliably. Portability data shows where a number lives, not whether the SIM is switched on or still in use. If you need to know whether a line is live, run an HLR lookup.
How often should I run MNP lookups on a list?
Check new numbers when they are collected, check whole lists before large campaigns, and recheck older segments every few months, because users keep switching networks and keep their numbers when they do.
Can I see the cost of a lookup before running it?
Yes. SMS.to has estimate endpoints for single numbers and batches that return the cost of an MNP lookup before you run it.
Want to see how many numbers in your list have moved networks? Create a free account, no credit card needed, and run your first lookups today.