E.164 & SMS Quick Reference: Comprehensive guide to Lebanon phone number formats (+961): structure, validation, and implementation. Includes landline/mobile prefixes (03, 70, 71, 01, 04-07, 09), regex for national/international formats, and number portability best practices. NSN length: 8 digits. Need real-time carrier, porting, and line-type validation beyond regex? Run live lookups with SMSRoute HLR Lookup or send directly over Tier-1 routes via the SMSRoute SMS API.
Format, validate, and handle Lebanon phone numbers in your applications. This guide covers the +961 country code, number structures, carrier identification (Alfa, Touch, Ogero), validation patterns, and security considerations for developers working with Lebanese telecommunications.
Quick Reference
- Country: Lebanon
- Country Code: +961
- International Prefix: 00 (from landlines) / + (from mobiles)
- National Prefix: 0
- Regulatory Authority: Telecommunications Regulatory Authority (TRA) (http://www.tra.gov.lb/)
- TRA Established: Law 431/2002, operational since February 2007
- NSN Length: 8 digits
- Mobile Number Portability: Not implemented (as of 2025)
- Latest Numbering Update: May 26, 2025 (Ministerial Decisions No. 172/1, 173/1) β Source: ITU Communication T02020000770005
How to Dial Lebanon Phone Numbers
From abroad to Lebanon: Dial your country's international access code + 961 + local number (without leading 0)
- From US: 011 961 1 234567 (calling Beirut number 01 234567)
- From UK: 00 961 3 123456 (calling mobile 03 123456)
Within Lebanon: Dial the full 8-digit number including area code with leading 0
- Example: 01 234567 (Beirut landline) or 03 123456 (mobile)
Emergency Numbers in Lebanon
- Police (Internal Security Forces): 112
- Ambulance (Lebanese Red Cross): 140
- Fire Department: 175 (Beirut: +961 1 445 000)
- Civil Defense: 125
- Lebanese Army: 1701
- General Security: 1717
Source: National News Agency
Understanding Lebanon Phone Number Format
The Telecommunications Regulatory Authority (TRA) manages Lebanon's numbering system, which combines fixed-line and mobile networks. All Lebanese numbers follow the ITU-T E.164 international phone number standard, with a maximum length of 15 digits in international format.
Core Structure
- International Format: +961 X XXXXXX (Example: +961 1 234567)
- National Format: 0X XXXXXX (Example: 01 234567)
When to Use Each Format:
- International format (+961XXXXXXXX): Use for database storage, API integrations, SMS/voice routing, international communications, and cross-border operations. This format ensures global compatibility.
- National format (0XXXXXXXX): Use for display to Lebanese users, local marketing materials, and printed materials within Lebanon. Accept this format as user input, but convert to international format before storage.
Handling User Input:
Users enter phone numbers with various formatting characters. Accept and normalize these variations:
const inputVariations = [
'+961 1 234567',
'+961-1-234567',
'+961 (1) 234567',
'961 1 234567',
'01 234 567',
'01-234-567',
'(01) 234567',
'01234567'
];
function normalizeLebanonNumber(input) {
const cleaned = input.replace(/[^\d+]/g, '').replace(/\+(?=.)/g, '');
if (cleaned.startsWith('+961') || cleaned.startsWith('961')) {
const digits = cleaned.replace(/^\+?961/, '');
if (digits.length === 8 && /^[1-9]/.test(digits)) {
return `+961${digits}`;
}
} else if (cleaned.startsWith('0') && cleaned.length === 8) {
return `+961${cleaned.substring(1)}`;
} else if (cleaned.length === 7 && /^[1-9]/.test(cleaned)) {
return `+961${cleaned}`;
}
return null;
}
Best Practice: Store phone numbers in your database using the E.164 international format (+961XXXXXXXX) without spaces or special characters. This ensures consistency and simplifies processing across your application.
Lebanon Area Codes and Mobile Prefixes
Identify Lebanese number types by prefix:
| Type | Prefix(es) | Format | Example | Usage Context |
|---|---|---|---|---|
| Landline (Beirut) | 01 | 01 XXX XXX | 01 234 567 | Beirut metropolitan area |
| Landline (Mount Lebanon) | 04, 05, 09 | 0X XXX XXX | 04 123 456 | Mount Lebanon (Metn, Baabda, Aley, Chouf, Kesrouan, Byblos) |
| Landline (North) | 06 | 06 XXX XXX | 06 234 567 | North Lebanon including Akkar |
| Landline (South) | 07 | 07 XXX XXX | 07 345 678 | South Lebanon |
| Landline (Bekaa) | 08 | 08 XXX XXX | 08 456 789 | Bekaa and Baalbek-Hermel Governorates |
| Mobile (Alfa) | 03 (031β035), 070 (1β5), 071 (6β9), 076 (1, 3β5), 079 (1β3), 081 (2β4) | 0XX XXX XXX | 03 123 456 | Alfa (MIC1) mobile network |
| Mobile (Touch) | 03 (030, 036β039), 070 (0, 6β9), 071 (1β5), 076 (0, 6β9), 078 (7β9), 081 (6β8) | 0XX XXX XXX | 76 234 567 | Touch (MIC2) mobile network |
Critical Note: Lebanon has not implemented Mobile Number Portability (MNP) as of 2025. Prefixes reliably indicate the carrier that originally assigned the number, but operators recycle numbers when subscribers switch providers or accounts become inactive.
Security Warning: Touch recycles prepaid numbers after 30 days of inactivity and postpaid numbers after 90 days. Alfa uses a digital system to randomly select and recycle inactive numbers.
Number Recycling Impact on Applications:
Number recycling creates these critical security and UX risks:
- Account takeover risk: New subscriber receives SMS verification codes meant for previous owner
- Privacy breaches: Personal data, notifications, and sensitive messages sent to wrong person
- Two-factor authentication bypass: Attacker obtains recycled number to hijack accounts
- Marketing/notification waste: Messages sent to users who never opted in
- Support ticket confusion: Multiple users with same historical phone number in your system
Mitigation: Implement phone number re-verification every 60β90 days for security-critical features. Use SMS OTP or phone call verification described in the Troubleshooting section.
How to Validate Lebanon Phone Numbers
Validate Lebanese phone numbers using regex patterns and validation logic. Since Lebanon doesn't have number portability, rely on prefix-based identification to determine the original carrier.
Validation Strategy
Client-side validation:
- Provide immediate feedback for formatting errors
- Use simple regex to check basic structure
- Display helpful error messages with example formats
- Allow partial validation as users type
Server-side validation:
- Always validate on server (never trust client alone)
- Use comprehensive regex with all prefix ranges
- Verify the number hasn't been blocklisted or recycled
- Log validation failures for monitoring
- Implement rate limiting to prevent enumeration attacks
Special Service Numbers:
Lebanon uses special short codes that should not be validated as regular numbers:
- Emergency services: 112, 125, 140, 175, 1701, 1717 (4 digits)
- Utility services: 1707 (ElectricitΓ© du Liban)
- MMS services: 119 (3 digits)
Explicitly exclude these short codes from validation, or handle them separately if your application needs to support them.
Regular Expressions for Lebanon Phone Number Validation
Use these regular expressions to validate Lebanese number types:
const internationalPattern = /^\+961[1-9]\d{6,7}$/;
const nationalPattern = /^0(?:1\d{6}|[4-9]\d{6}|3(?:0|1[1-5]|[2-5]|6[6-9]|7|8|9)\d{5}|70[0-9]\d{5}|71[0-9]\d{5}|76[0-9]\d{5}|78[7-9]\d{5}|79[1-3]\d{5}|81[0-9]\d{5})$/;
const landlinePattern = /^0[1456789]\d{6}$/;
const mobilePattern = /^0(?:3(?:0|1[1-5]|[2-5]|6[6-9]|7|8|9)|70[0-9]|71[0-9]|76[0-9]|78[7-9]|79[1-3]|81[0-9])\d{5}$/;
const emergencyPattern = /^(112|125|140|175|1701|1707|1717|119)$/;
function isValidLebaneseNumber(number) {
return internationalPattern.test(number) || nationalPattern.test(number);
}
function isLebaneseMobile(number) {
const cleaned = number.replace(/^\+961/, '0').replace(/\D/g, '');
return mobilePattern.test(cleaned);
}
function isEmergencyNumber(number) {
const cleaned = number.replace(/\D/g, '');
return emergencyPattern.test(cleaned);
}
const testCases = [
{ input: '+9613123456', expected: true, type: 'Alfa mobile' },
{ input: '+9617623456', expected: true, type: 'Touch mobile' },
{ input: '+9617870000', expected: true, type: 'Touch mobile (new range)' },
{ input: '03123456', expected: true, type: 'Mobile national' },
{ input: '07012345', expected: true, type: 'Mobile 070 range' },
{ input: '07612345', expected: true, type: 'Mobile 076 range' },
{ input: '+9611234567', expected: true, type: 'Beirut landline' },
{ input: '01234567', expected: true, type: 'Beirut national' },
{ input: '04123456', expected: true, type: 'Mount Lebanon' },
{ input: '+96112345', expected: false, type: 'Too short' },
{ input: '+961012345678', expected: false, type: 'Leading zero in intl' },
{ input: '12345678', expected: false, type: 'Missing prefix' },
{ input: '+961 1 234567', expected: false, type: 'Contains spaces' },
{ input: '112', expected: true, type: 'Police emergency' },
{ input: '140', expected: true, type: 'Ambulance emergency' },
];
testCases.forEach(test => {
const result = isValidLebaneseNumber(test.input) || isEmergencyNumber(test.input);
console.log(`${test.type}: ${result === test.expected ? 'PASS' : 'FAIL'}`);
});
Phone Number Formatting and Sanitization
Maintain consistent formatting to improve data quality and user experience:
function sanitizePhoneNumber(input) {
return input.replace(/\D/g, '');
}
function formatLebaneseNumber(number) {
const cleaned = sanitizePhoneNumber(number);
if (cleaned.length === 8 && /^[0-9]/.test(cleaned)) {
const withoutLeadingZero = cleaned.startsWith('0') ? cleaned.substring(1) : cleaned;
return `+961${withoutLeadingZero}`;
} else if (cleaned.startsWith('961') && cleaned.length === 11) {
return `+${cleaned}`;
} else if (cleaned.startsWith('0') && cleaned.length === 8) {
return `+961${cleaned.substring(1)}`;
} else if (!cleaned.startsWith('0') && cleaned.length === 7) {
return `+961${cleaned}`;
}
return null;
}
function formatWithErrorHandling(number) {
const formatted = formatLebaneseNumber(number);
if (formatted === null) {
console.error('Invalid Lebanese phone number format:', number);
throw new Error(
'Invalid phone number format. Enter a Lebanese number ' +
'like 01 234567 (national) or +961 1 234567 (international)'
);
}
return formatted;
}
function processUserPhoneInput(rawInput) {
try {
const normalized = normalizeLebanonNumber(rawInput);
if (!normalized) {
return {
success: false,
error: 'Unable to parse phone number. Check the format.',
example: '+961 1 234567 or 01 234567'
};
}
if (!isValidLebaneseNumber(normalized) && !isEmergencyNumber(normalized)) {
return {
success: false,
error: 'Invalid Lebanese phone number.',
details: 'Number must start with valid prefix (01-09, 70-79, 81)',
example: '03 123456 (mobile) or 01 234567 (landline)'
};
}
const formatted = formatLebaneseNumber(normalized);
const carrier = identifyCarrier(formatted);
return {
success: true,
formatted: formatted,
carrier: carrier,
type: isLebaneseMobile(formatted) ? 'mobile' : 'landline'
};
} catch (error) {
return {
success: false,
error: error.message
};
}
}
const result = processUserPhoneInput('03-123-456');
if (result.success) {
console.log('Formatted:', result.formatted);
console.log('Carrier:', result.carrier);
console.log('Type:', result.type);
} else {
console.error('Error:', result.error);
}
Lebanon Mobile Carriers: Alfa and Touch
Lebanon operates three state-owned telecommunications providers:
- Alfa (MIC1): State-owned mobile operator managed by Orascom Telecom. Uses prefixes 03 (031β035), 070 (1β5), 071 (6β9), 076 (1, 3β5), 079 (1β3), and 081 (2β4). Originally launched in 1994 as the first GSM network in Lebanon.
- Touch (MIC2): State-owned mobile operator managed by Zain Group. Uses prefixes 03 (030, 036β039), 070 (0, 6β9), 071 (1β5), 076 (0, 6β9), 078 (7β9), and 081 (6β8). Formerly known as MTC Touch.
- Ogero Telecom: Government-owned fixed infrastructure operator handling all landline services (prefixes 01, 04β09). Founded in 1972, Ogero provides backbone infrastructure for all telecom networks, including mobile operators, Data Service Providers (DSPs), and Internet Service Providers (ISPs).
MVNO Status: Lebanon does not have Mobile Virtual Network Operators (MVNOs) or third-party mobile providers. Alfa and Touch provide all mobile services exclusively. No regulatory framework for MVNO licensing exists as of 2025, though this may change with future telecommunications reforms.
Number Portability Status: Lebanon has not implemented Mobile Number Portability (MNP) as of 2025. Users surrender their number when switching between Alfa and Touch. You can reliably use prefix-based carrier identification to determine the original network assignment.
Number Recycling Practices
Understand how operators recycle inactive numbers:
- Touch: Recycles prepaid numbers after 30 days of inactivity; recycles postpaid numbers after 90 days
- Alfa: Uses a digital system that randomly selects inactive numbers for recycling and re-release
Developer Implication: If your application requires long-term number ownership verification (security, account recovery), implement periodic re-verification. Don't assume permanent number-to-user associations given aggressive recycling timelines.
Re-verification Implementation:
const userSchema = {
id: 'string',
phone: 'string',
phoneVerified: 'boolean',
phoneVerifiedAt: 'timestamp',
phoneVerificationCode: 'string',
phoneVerificationExpiry: 'timestamp'
};
function needsPhoneReverification(user) {
if (!user.phoneVerified) return true;
const daysSinceVerification =
(Date.now() - user.phoneVerifiedAt) / (1000 * 60 * 60 * 24);
return daysSinceVerification > 60;
}
async function performSecureOperation(userId) {
const user = await getUser(userId);
if (needsPhoneReverification(user)) {
await sendSMSVerification(user.phone);
return {
success: false,
requiresVerification: true,
message: 'Verify your phone number to continue'
};
}
return await executeSecureOperation(user);
}
async function sendSMSVerification(phoneNumber) {
const code = generateSecureCode(6);
const expiry = Date.now() + (10 * 60 * 1000);
await updateUser({
phoneVerificationCode: hashCode(code),
phoneVerificationExpiry: expiry,
phoneVerified: false
});
await smsProvider.send({
to: phoneNumber,
message: `Your verification code is ${code}. Valid for 10 minutes.`
});
}
async function verifyPhoneCode(userId, submittedCode) {
const user = await getUser(userId);
if (Date.now() > user.phoneVerificationExpiry) {
return { success: false, error: 'Code expired' };
}
if (hashCode(submittedCode) === user.phoneVerificationCode) {
await updateUser({
phoneVerified: true,
phoneVerifiedAt: Date.now(),
phoneVerificationCode: null
});
return { success: true };
}
return { success: false, error: 'Invalid code' };
}
Troubleshooting Lebanon Phone Number Issues
Common issues when handling Lebanese phone numbers:
Leading Zero Errors
- Problem: Missing or incorrect leading zero placement
- Solution: Include the leading zero in national format (01 234567) but remove it in international format (+961 1 234567)
- Fix: Use the normalization function above to handle both formats
Invalid Prefix Errors
- Problem: Your validation rejects a valid Lebanese number
- Solution: Verify the prefix exists in the table above. Common mistakes include assuming all 03 numbers belong to Alfa when some (030, 036β039) belong to Touch. Update your regex to include new ranges 76, 78, 79, and 81 added in May 2025.
- Debugging tip: Log rejected numbers with prefixes to identify patterns
Carrier Misidentification
- Problem: Your system assigns the wrong carrier to a number
- Solution: Use the specific prefix ranges listed in the carrier section. Lebanon doesn't have MNP, so prefix-based lookup remains reliable. Reference ITU numbering plan updates.
- Example:
function identifyCarrier(phoneNumber) {
const national = phoneNumber.replace(/^\+961/, '0');
const alfaPrefixes = /^0(?:3[1-5]|70[1-5]|71[6-9]|76[1345]|79[1-3]|81[234])/;
const touchPrefixes = /^0(?:30|3[6-9]|70[0689]|71[1-5]|76[0689]|78[789]|81[678])/;
if (alfaPrefixes.test(national)) {
return 'Alfa (MIC1)';
} else if (touchPrefixes.test(national)) {
return 'Touch (MIC2)';
} else if (/^0[1456789]/.test(national)) {
return 'Ogero (Landline)';
}
return 'Unknown';
}
Number Recycling Issues
- Problem: A phone number that worked for one user now belongs to someone else
- Solution: Implement regular verification checks using SMS OTP or phone call verification. Numbers can be reassigned after 30β90 days of inactivity
Verification Methods:
- SMS OTP (One-Time Password): Send 6-digit code via SMS, user enters code within 10 minutes
- Phone Call Verification: Make automated call with spoken code or callback verification
- Silent SMS Verification: Send SMS with delivery receipt (less intrusive but less secure)
Production Debugging Tips:
- Structured logging: Log validation failures with input format, detected prefix, and rejection reason
- Metrics tracking: Monitor validation failure rates by prefix to catch new number ranges
- User feedback loop: Allow users to report "number not accepted" issues
- Test with real data: Maintain test suite with real Lebanese numbers (anonymized) covering all prefixes
function validateWithLogging(phoneNumber, context = {}) {
const result = processUserPhoneInput(phoneNumber);
if (!result.success) {
logger.warn('Phone validation failed', {
input: maskPhoneNumber(phoneNumber),
error: result.error,
context: context,
timestamp: new Date().toISOString()
});
}
return result;
}
function maskPhoneNumber(phone) {
if (phone.length < 8) return phone;
return phone.slice(0, -6) + '****' + phone.slice(-2);
}
Best Practices for Lebanon Phone Number Implementation
Handle Lebanese phone numbers effectively:
Input Sanitization Sanitize user input to remove non-digit characters, spaces, and formatting before validation. Use the normalizeLebanonNumber() function provided above.
Comprehensive Validation Use regular expressions that cover all valid prefix ranges, including the new 76, 78, 79, and 81 ranges added in May 2025. Don't rely on length checks alone.
Clear Error Messages Write specific error messages that help users fix issues:
- Instead of "Invalid phone number," say "Lebanese phone numbers must start with 0 and have 8 digits (e.g., 01 234567)"
- Instead of "Wrong format," say "Enter your number with the country code (+961 1 234567) or without (01 234567)"
Internationalization Accept and display both national and international formats seamlessly. Convert to E.164 for storage, display in user's preferred format.
Stay Updated Monitor TRA regulations for changes to the numbering plan or MNP implementation announcements. The most recent update was May 26, 2025. Subscribe to ITU operational bulletins or TRA updates at http://www.tra.gov.lb/.
Account Security Given rapid number recycling (30β90 days), avoid using phone numbers as sole authentication or account recovery. Implement additional verification methods like email or security keys.
Prefix-Based Routing Since Lebanon doesn't have MNP, reliably route SMS and calls based on prefix to optimize costs through carrier-specific agreements.
Routing Implementation:
const carrierRoutes = {
'Alfa': {
prefixes: ['31', '32', '33', '34', '35', '701', '702', '703', '704',
'705', '716', '717', '718', '719', '761', '763', '764', '765',
'791', '792', '793', '812', '813', '814'],
provider: 'alfa-sms-gateway',
costPerSMS: 0.045
},
'Touch': {
prefixes: ['30', '36', '37', '38', '39', '700', '706', '707', '708',
'709', '711', '712', '713', '714', '715', '760', '766', '767',
'768', '769', '787', '788', '789', '816', '817', '818'],
provider: 'touch-sms-gateway',
costPerSMS: 0.043
}
};
function routeSMSByCarrier(phoneNumber, message) {
const carrier = identifyCarrier(phoneNumber);
const route = carrierRoutes[carrier];
if (!route) {
throw new Error(`No route configured for carrier: ${carrier}`);
}
return {
gateway: route.provider,
recipient: phoneNumber,
message: message,
estimatedCost: route.costPerSMS
};
}
async function sendBulkSMS(recipients, message) {
const byCarrier = recipients.reduce((acc, phone) => {
const carrier = identifyCarrier(phone);
if (!acc[carrier]) acc[carrier] = [];
acc[carrier].push(phone);
return acc;
}, {});
const results = await Promise.all(
Object.entries(byCarrier).map(([carrier, phones]) => {
const route = carrierRoutes[carrier];
return sendViaGateway(route.provider, phones, message);
})
);
const totalCost = results.reduce((sum, r) => sum + r.cost, 0);
const singleRouteCost = recipients.length * 0.05;
const savings = singleRouteCost - totalCost;
console.log(`Sent ${recipients.length} SMS via optimized routing`);
console.log(`Cost: $${totalCost.toFixed(2)} (saved $${savings.toFixed(2)})`);
return results;
}
Typical Cost Optimization:
- Direct carrier routing: 10β20% cost reduction compared to generic SMS gateways
- Reduced failed delivery rates due to proper carrier identification
- Better delivery speeds through direct carrier connections
Performance Considerations:
- Regex caching: Compile regex patterns once, reuse for all validations
- Bulk validation: Process phone numbers in batches when validating large datasets
- Database indexing: Index phone number columns for fast lookup
- Rate limiting: Implement rate limits on SMS verification to prevent abuse (3 attempts per number per hour)
class LebanonPhoneValidator {
constructor() {
this.patterns = {
international: /^\+961[1-9]\d{6,7}$/,
national: /^0(?:1\d{6}|[4-9]\d{6}|3(?:0|1[1-5]|[2-5]|6[6-9]|7|8|9)\d{5}|70[0-9]\d{5}|71[0-9]\d{5}|76[0-9]\d{5}|78[7-9]\d{5}|79[1-3]\d{5}|81[0-9]\d{5})$/,
mobile: /^0(?:3(?:0|1[1-5]|[2-5]|6[6-9]|7|8|9)|70[0-9]|71[0-9]|76[0-9]|78[7-9]|79[1-3]|81[0-9])\d{5}$/,
emergency: /^(112|125|140|175|1701|1707|1717|119)$/
};
}
validate(number) {
return this.patterns.international.test(number) ||
this.patterns.national.test(number);
}
isMobile(number) {
const cleaned = number.replace(/^\+961/, '0').replace(/\D/g, '');
return this.patterns.mobile.test(cleaned);
}
}
const validator = new LebanonPhoneValidator();
validator.validate('+9613123456');
Frequently Asked Questions
What is the country code for Lebanon?
The international country code for Lebanon is +961. When dialing from abroad, dial +961 followed by the 8-digit national number (without the leading 0). To call 01 234567 from outside Lebanon, dial +961 1 234567.
How many digits are in a Lebanon phone number?
Lebanese phone numbers contain 8 digits in national format (NSN length). When including the country code, the full international format is 11 digits: +961 followed by 8 digits.
Does Lebanon have mobile number portability?
No, Lebanon has not implemented Mobile Number Portability (MNP) as of 2025. Users give up their phone number when switching between Alfa and Touch mobile operators. You can reliably identify carriers based on number prefixes.
What are Lebanon mobile number prefixes?
Lebanon mobile numbers use these prefixes:
- Alfa (MIC1): 03 (031β035), 070 (1β5), 071 (6β9), 076 (1, 3β5), 079 (1β3), 081 (2β4)
- Touch (MIC2): 03 (030, 036β039), 070 (0, 6β9), 071 (1β5), 076 (0, 6β9), 078 (7β9), 081 (6β8)
Some 03 prefixes belong to Alfa while others belong to Touch β check the specific ranges for accurate carrier identification. New mobile prefixes 76, 78, 79, and 81 were added in May 2025 per ITU Communication.
How do I format a Lebanon phone number for international dialing?
Format Lebanese numbers for international use in E.164 format: +961XXXXXXXX (no spaces or special characters). Remove the leading 0 from the national format and prefix with +961. Example: 01 234567 becomes +9611234567.
What is Lebanon's Beirut area code?
Beirut's area code is 01. Within Lebanon, dial 01 followed by 6 digits. From abroad, dial +961 1 followed by 6 digits. The 01 prefix identifies landline numbers in the Beirut metropolitan area.
How long before Lebanon mobile numbers are recycled?
Lebanon mobile operators recycle inactive numbers quickly:
- Touch: Recycles prepaid after 30 days, postpaid after 90 days
- Alfa: Uses random selection for recycling inactive numbers
This aggressive recycling means phone numbers can be reassigned to new users within 1β3 months of inactivity.
How do I validate a Lebanon phone number in JavaScript?
Use regex patterns to validate Lebanese numbers. For international format:
const pattern = /^\+961[1-9]\d{6,7}$/;
For national format with comprehensive prefix validation, see the full patterns in the validation section above. Include the new 76, 78, 79, and 81 prefixes added in May 2025.
Additional Resources
Explore these official sources for more information:
- TRA Official Website: http://www.tra.gov.lb/
- ITU E.164 Standard: E.164 Phone Format Guide
- ITU Operational Bulletin: Lebanon Numbering Plan Updates
- Ogero Telecom: https://www.ogero.gov.lb/
- Alfa Mobile: https://www.alfa.com.lb/
- Touch Mobile: https://www.touch.com.lb/
Phone Validation Libraries:
- libphonenumber: Google's comprehensive phone number parsing, formatting, and validation library (GitHub)
- libphonenumber-js: JavaScript port of libphonenumber, smaller bundle size (GitHub)
- phone: Lightweight phone validation library (npm)
Next Steps
Implement Lebanese phone number handling in your application:
- Copy the validation patterns from the Regular Expressions section into your codebase
- Update your database schema to store numbers in E.164 international format (+961XXXXXXXX)
- Implement input sanitization to handle various user input formats using the normalizeLebanonNumber() function
- Add carrier identification logic using the prefix tables and identifyCarrier() function above
- Set up periodic verification for security-critical applications to handle number recycling (every 60β90 days)
- Write clear error messages that help users correct formatting issues
- Optimize SMS routing by carrier to reduce costs by 10β20%
- Monitor and log validation failures to catch new number ranges or patterns
Database Schema Example:
CREATE TABLE users (
id UUID PRIMARY KEY,
email VARCHAR(255) NOT NULL,
phone VARCHAR(15),
phone_verified BOOLEAN DEFAULT FALSE,
phone_verified_at TIMESTAMP,
phone_carrier VARCHAR(20),
phone_type VARCHAR(10),
created_at TIMESTAMP DEFAULT NOW(),
updated_at TIMESTAMP DEFAULT NOW()
);
CREATE INDEX idx_users_phone ON users(phone);
UPDATE users
SET phone = '+961' || LTRIM(phone, '0')
WHERE phone LIKE '0%' AND LENGTH(phone) = 8;
Lebanon hasn't implemented mobile number portability, which means prefix-based carrier identification remains reliable. However, aggressive number recycling practices (30β90 days) may affect long-term number-to-user associations. Stay informed about TRA regulatory changes and monitor ITU operational bulletins for numbering plan updates. The most recent update was May 26, 2025 (Ministerial Decisions No. 172/1, 173/1), adding new mobile number ranges.
The country code for Lebanon is +961. This code is required when dialing Lebanese numbers from outside the country. It precedes the area code and subscriber number.
Store Lebanese phone numbers in the international format (+961XXXXXXXX) without spaces or special characters. This ensures consistency and simplifies processing, regardless of the original input format.
Lebanese phone numbers follow the ITU-T E.164 standard, with a maximum length of 15 digits in the international format (+961 X XXXXXX) and 8 digits in the national format (0X XXXXXX).
Use regular expressions like ^\+961[1-9]\d{6,7}$ for international format and ^0(?:[14-79][\d]{6}|3(?:[\d]{6}|[0-9][\d]{7})|7(?:0|1|6|8|9)[\d]{6}|81[2-8]\d{5})$ for national format for accurate validation and to account for variations in prefixes.
Number portability allows users to change carriers while keeping their number, making prefix-based validation unreliable. A comprehensive approach including regular expressions and carrier lookup APIs is recommended.
The national prefix for calls within Lebanon is 0. It precedes the area code when dialing landlines or mobile numbers domestically.
Remove all non-digit characters from user input using a function or regular expression like replace(/\D/g, '') to ensure data consistency and prevent errors during validation and processing.
The Telecommunications Regulatory Authority (TRA) regulates Lebanon's fixed-line and mobile networks, ensuring compliance with international standards and managing the numbering system.
Due to number portability, relying on prefixes for carrier identification is unreliable. Integrate a real-time carrier lookup API or consider caching lookup results with a reasonable TTL.
Use a carrier lookup API when accurate carrier identification is crucial, such as for routing calls or applying carrier-specific logic. Balance real-time lookups with caching for performance.
Lebanon has two main mobile carriers: Alfa (MIC1) with prefixes 03, 70, 71 and some 07x numbers and Touch (MIC2) using prefixes 76, 78, 79 and some 07x, 03x and 081x numbers.
No, relying solely on prefixes to identify carriers is unreliable due to number portability. Subscribers can switch operators while retaining their existing number.
Lebanese National Significant Numbers (NSNs) have 8 digits. These digits follow the national prefix (0) and the area code when dialing within Lebanon.
Validate & Send SMS to Lebanon With SMSRoute
Regex catches syntax mistakes, but it cannot tell you whether a mobile number is active, ported to another carrier, or reachable over SMS. Before launching OTP or transactional campaigns into Lebanon, pair E.164 normalization with live carrier intelligence and direct Tier-1 termination on SMSRoute.
curl -X POST https://api.sendsmsnokyc.com/v3/messages \
-H "x-api-key: $SMSROUTE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"to": ["+14155551234"],
"channel": ["sms"],
"body": "Your verification code is 482910"
}'
- Live HLR & Carrier Lookup: Verify active status, roaming, and current serving network before you pay to send via SMSRoute HLR Lookup.
- Handset-Verified Route Testing: Audit real SIM delivery, DLR latency, and Sender ID preservation with Live Carrier Testing.
- No-KYC Instant Onboarding: Fund with crypto (BTC/USDT) or card and check exact per-country rates on our live pricing page.
Deliver Global SMS With Direct Carrier Routes
Validate E.164 numbers with live HLR lookup and deliver high-priority OTPs and alerts across 190+ countries on SMSRoute.
Try SMSRoute HLR Lookup β