How to Extract Phone Numbers from a Website
You're looking at a web page with phone numbers on it — a business directory, a contact page, a list of vendors — and you need those numbers in a usable format. Not embedded in HTML, not surrounded by addresses and opening hours. Just the numbers.
Here's how to get them out fast.
The Copy-Paste Method (Works Everywhere)
The simplest approach requires no tools, extensions, or technical knowledge:
- Go to the web page with phone numbers
- Select all text on the page (Ctrl/Cmd+A)
- Copy (Ctrl/Cmd+C)
- Paste into NumSwift's phone number extractor
- Every phone number on the page is extracted with instant call, WhatsApp, and SMS actions
NumSwift ignores navigation menus, image alt text, footer disclaimers, and everything else that isn't a phone number. You don't need to carefully select just the contact section — paste the entire page and let it filter.
This is the same extract-from-text technique that works with emails and documents, just applied to web content.
Business Directories and Listings
Directory pages — Yellow Pages, Yelp, industry-specific listings — often have dozens or hundreds of phone numbers on a single page.
Single Page
Select all, copy, paste into NumSwift. Every number from every listing on that page gets extracted and deduplicated.
Multiple Pages
If the directory spans multiple pages:
- Open each page
- Select all and copy the text
- Paste all pages' text into NumSwift at once
NumSwift handles any volume of pasted text and automatically removes duplicate numbers that appear on multiple pages.
For directories with hundreds of listings, the bulk phone number extractor processes large volumes without slowing down.
Contact Pages
Company contact pages typically have one or two phone numbers mixed in with addresses, email links, and maps. The copy-paste method works, but you can also:
- Triple-click to select just the line containing the number
- Copy and paste into NumSwift
- Get a clean, formatted number with action buttons
This is useful when you want a specific number from a page that lists multiple departments.
When Copy-Paste Doesn't Work
Some websites make phone numbers hard to copy:
Numbers Rendered as Images
Some sites display phone numbers as images to prevent scraping. You can't select or copy image text.
Solutions:
- iPhone/Mac: Use Live Text — hover over the image and the number becomes selectable
- Android: Use Google Lens — point at the number to copy it
- Desktop: Take a screenshot and use an OCR tool, then paste the result into NumSwift
Numbers Behind JavaScript
Some pages load phone numbers dynamically — a "Show phone number" button that reveals the number after a click.
Solution: Click to reveal the number, then copy it normally. These buttons exist to track clicks, not to prevent copying.
Numbers Split Across Elements
A few sites split numbers across HTML elements to block automated scraping: <span>555</span><span>-123-</span><span>4567</span>. When you copy, you get the full number — this technique only blocks bots, not humans.
View Source Method (For Technical Users)
If numbers are embedded in the page but not easily selectable:
- Right-click on the page → View Page Source (or press Ctrl/Cmd+U)
- Search the source code (Ctrl/Cmd+F) for phone number patterns — try searching for
tel:,href="tel", or the area code - Copy the relevant section of source code
- Paste into NumSwift — it extracts phone numbers even from HTML markup
The tel: protocol in links is a reliable indicator: <a href="tel:+15551234567"> always contains a real phone number.
Developer Console Method
For pages where numbers load dynamically:
- Open Developer Tools (F12 or Ctrl/Cmd+Shift+I)
- Go to the Elements tab
- Use Ctrl/Cmd+F to search the DOM for phone-number-like patterns
- Copy what you find
This works when numbers are loaded via JavaScript after the initial page render.
Extracting Numbers from Multiple Websites
If you're researching vendors, collecting business contacts, or building a call list from multiple sites:
- Visit each site
- Copy the contact section
- Paste all copied text into NumSwift in one go
NumSwift deduplicates automatically, so if the same business appears on multiple sites with the same number, you'll see it only once. For processing large contact lists, see our guide on extracting numbers from spreadsheets.
International Numbers on Websites
Websites serving multiple countries often display numbers in local formats without country codes. A UK site shows 020 7946 0958 instead of +44 20 7946 0958.
Set your default country in NumSwift before pasting. It uses libphonenumber — the same library that powers Android's dialer — to parse local formats correctly. For a reference on country-specific formatting, see our international phone number format guide.
A Note on Web Scraping
Automated scraping — using scripts to extract data from websites at scale — is a different use case entirely. It involves writing code, handling rate limits, and navigating legal considerations around website terms of service.
The methods in this guide are for manually copying publicly visible information from web pages you're already looking at. No scripts, no automation, no ethical gray areas. You're just copying text from a screen — the same thing you'd do with a pen and paper, but faster.
Tips
-
Select All is your friend. Don't try to surgically select just the phone numbers. Grab everything on the page and let NumSwift sort it out.
-
Check for hidden numbers. Some sites have "Click to reveal" buttons for phone numbers. Click them before copying the page text.
-
Watch for fake numbers. Some directories use placeholder or tracking numbers. If a number seems wrong, try calling it before adding it to your list.
-
Use the right country setting. Local numbers without country codes need the correct default country to parse properly.
Related Guides
- How to extract phone numbers from any text — the foundational technique behind website extraction
- How to extract phone numbers from a PDF — when website content is available as a downloadable PDF
- Phone number extractor for sales teams — workflow for building call lists from online research
- How to extract phone numbers from screenshots — when website numbers are displayed as images
Bottom Line
For phone numbers on any web page — directories, contact pages, listings — select the text, copy, and paste into NumSwift. It extracts every valid phone number and gives you instant call, WhatsApp, and SMS actions. No browser extensions, no scraping tools, no manual copying one number at a time.