How to Remove Phone Numbers from Text Online

How to Remove Phone Numbers from Text Online

How to remove phone numbers from text online: strip US, UK and international numbers, extensions included, and keep dates and prices intact, in your browser.

How to Remove Phone Numbers from Text Online

Paste your text into a phone number remover, and every number comes out while the rest of the sentence stays put. “Call (555) 123-4567 for details” becomes “Call for details” — the words survive and the number is gone.

A phone number is not one shape. In the US it can look like (555) 123-4567, 555-123-4567 or +1 555 123 4567. In the UK it can look like 07700 900461, +44 7700 900461 or 020 7946 0958. Some numbers carry an extension — “ext. 123” — and some carry a country code. A tool that only looks for one shape will miss the rest, and a tool that is too eager will strip a date, a price or an order number that was never a phone number at all.

Key takeaways

  • Removing phone numbers deletes numbers only. Words, dates, prices, order numbers and email addresses stay.
  • Pick the mode first: delete every number, replace each one with a placeholder like [phone], keep only the numbers and drop the rest of the text, or mask part of each number.
  • Phone numbers come in more shapes than (555) 123-4567 — UK numbers, country codes, extensions and different separators all count, and a good tool catches all of them.
  • A phone number is not just any run of digits. Dates, prices, years, order IDs and ZIP codes look similar and must survive.
  • Watch the extension. “ext. 123” and “x123” belong to the number, and a tool that leaves them behind has only done half the job.
  • Removing a number does not remove the spaces around it. Expect double spaces where a number sat between two words.
  • Word, Google Docs and Excel have no command that removes phone numbers from text.

What counts as a phone number?

Before running anything, it helps to know what you are asking the tool to find. The international standard for phone-number structure is E.164, published by the ITU: a country code, then a national number. In ordinary text, numbers show up with punctuation, spaces and brackets everywhere.

US numbers are the ones most tools are built for. A typical US number is ten digits — a three-digit area code and a seven-digit local number — and in text it appears as (555) 123-4567, 555-123-4567 or +1 555 123 4567. A matcher that only recognises one separator will miss the others.

UK numbers are a different shape, and this is where most tools fall short. A UK mobile looks like 07700 900461 — eleven digits starting with 07 — and a landline like 020 7946 0958. With the country code the leading zero drops away: +44 7700 900461. A tool built only for US numbers will walk straight past both.

Then there are the attached pieces. An extension — “ext. 123”, “x123”, “extension 123” — is part of the number.

What is not a phone number matters just as much. A date like 12/03/2026, a price like $49.99, a year like 2026, an order ID like 884193, a ZIP code like 90210 and a time like 9:00 are all runs of digits a careless tool will happily delete. The difference is structure: a phone number has a recognisable grouping — area code, exchange, line number — with a country code or an extension attached.

Choose the mode before you paste anything

Most phone number removers offer more than one operation, and they are not interchangeable. The table below is the decision to make first — the same text gives a different result under each one.

ModeWhat it doesUse it when
Delete all numbersEvery phone number is removed and nothing takes its placeCleaning a caption, a product description or a spreadsheet column
Replace with placeholderEach number becomes [phone], [PHONE] or a word you chooseSharing a log, ticket or AI prompt where the reader should know a number was there
Keep only numbersEverything except the numbers is deleted, leaving a list of phone numbersPulling every number out of a long document to build a contact list
Mask partially(555) 123-4567 becomes (555) ***-4567Showing which number is meant without showing the whole thing

Delete-all is the default most people want. The placeholder mode earns its place when the sentence depends on the number. Keep-only is an extraction, not a cleanup. Masking is the middle ground: the reader can tell which number is meant but cannot dial it.

How to remove phone numbers from text online

The whole job takes under a minute with a browser tool, and nothing needs to be uploaded — the text never leaves your own browser.

First, copy the text that contains the numbers and paste it into the tool’s input box. Choose the mode: delete all, replace with a placeholder, keep only the numbers, or mask them. If the tool has separate toggles for US, UK and international numbers, switch on the ones your text actually contains — a US-only setting will miss every UK number in the paste. Turn on the “tidy spaces” option if there is one, because it collapses the double spaces left behind. Click the remove button, read the result, and copy it out.

Before you paste the result where it is going, read it once. The check takes ten seconds and catches the two most common mistakes: a number the tool missed — usually a UK number, an extension or a number with a country code — and a date or price the tool deleted by accident.

The trap: other numbers that look like phone numbers

This is where phone number removal goes wrong most often, and why a plain “remove all numbers” button is a bad idea for this job. A phone number is a run of digits with a recognisable shape — but so are a lot of other things.

Dates are the first casualty. “Meeting on 12/03/2026 at 9:00” contains digits, slashes and a colon, and a loose pattern will take the date out along with the numbers. Prices are next: “$49.99” and “£1,250” belong in the text. Years, order IDs and ZIP codes are the quiet ones — “Order 884193 shipped in 2026 to 90210” has three runs of digits and none of them is a phone number.

The way to tell them apart is the shape, not the digits. A phone number has a grouping a date or a price does not: an area code in brackets, a country code with a plus sign, ten or eleven digits broken into two or three groups. A tool that understands grouping will leave the date and the price alone; a tool that only looks for “a run of digits” will not.

Test a tool before trusting it with a long document. Paste one line with a phone number, a date and a price — “Call (555) 123-4567 on 12/03/2026, total $49.99” — and look at what comes back. The number should be gone and the date and price still there. If the date is gone too, the tool is removing numbers, not phone numbers — see the general guide to removing numbers from text.

Extensions and country codes

An extension is the part of a phone number most tools forget. “Call 020 7946 0958 ext. 123” is one number with an extension, and a tool that removes the main number but leaves “ext. 123” behind has left a fragment that can still identify the person who owns the extension. The same goes for the short forms “x123” and “extension 123”.

Country codes are the other half of the same problem. The same UK mobile appears as 07700 900461 in one document and +44 7700 900461 in another, and a tool has to catch both. If the tool only matches numbers that start with a digit, the plus sign in front of the country code can break the match entirely.

When you test a tool, use a line with an extension and a country code: “Reach us on +44 7700 900461 ext. 123”. The whole thing — code, number and extension — should come out together. If the extension survives, run a second pass on the extension pattern, or pick a tool that lists extensions as a feature.

What happens to the spaces

Removing a phone number does not remove the spaces around it. “Call (555) 123-4567 for details” has one space before the number and one after it. Delete the number and both spaces remain: “Call for details” — two spaces where there should be one.

The fix is a second pass that collapses repeated spaces into one. Most phone number tools offer this as a “tidy whitespace” or “collapse spaces” option — turn it on and the problem goes away in the same run. If the tool does not offer it, it is the same operation as removing spaces that appear twice in a row.

Removing phone numbers in Word, Google Docs and Excel

Word, Google Docs and Excel have no command that removes phone numbers from plain text. What they have instead are half-measures that look like a solution until you try them.

In Word, Find and Replace can search for a pattern with wildcards, but it cannot reliably match every shape of phone number in one pass — US brackets, UK mobiles, country codes and extensions each need a different pattern, and running four passes is slower than using a browser tool.

Google Docs is in the same position: no built-in “remove all phone numbers” command, and Find and Replace works on literal text or simple patterns, not on the range of shapes a phone number takes. Excel is similar again — there is no built-in way to strip phone numbers out of cell contents, and a formula that deletes digits would also delete the dates and prices in the same column.

Doing it in code: Python and JavaScript

If the same cleanup runs every day — a daily export, a support queue, a feed — doing it by hand stops making sense.

In Python, the standard library’s re module does the work in a few lines. This pattern matches common US shapes, with an optional country code and extension:

import re

def remove_phones(text):
    pattern = r'\+?1?[\s.-]?\(?\d{3}\)?[\s.-]?\d{3}[\s.-]?\d{4}(\s*(ext\.?|x)\s*\d+)?'
    text = re.sub(pattern, '', text)
    return re.sub(r' {2,}', ' ', text).strip()

It catches (555) 123-4567, 555-123-4567 and +1 555 123 4567, plus an extension written as “ext. 123” or “x123”. It is a starting point: it will not catch UK numbers, which need a separate pattern for the 07 and 020 shapes, and it can catch a long order ID with the right digit count.

In JavaScript, the same idea:

function removePhones(text) {
  const pattern = /\+?1?[\s.-]?\(?\d{3}\)?[\s.-]?\d{3}[\s.-]?\d{4}(\s*(ext\.?|x)\s*\d+)?/g;
  return text
    .replace(pattern, '')
    .replace(/ {2,}/g, ' ')
    .trim();
}

Both snippets collapse double spaces as part of the same pass. If the job also involves UK numbers, add a second pattern for an 07 mobile or a 020 landline, with or without +44, and run it first so nothing gets half-matched.

Why people remove phone numbers at all: sharing safely

Most of the time, a phone number in a block of text is just clutter. But there is a second reason people run this job: the number belongs to a real person, and the text is about to be shared somewhere that person never agreed to.

Support tickets, chat exports, log files and screenshots all carry phone numbers, and they get pasted into public forums, shared with vendors, or fed into AI assistants. Once a number is in a public post or a third-party system, it cannot be taken back, and unlike an email address it can be called or messaged directly. Removing it before sharing is the simple version of redaction: the number is gone, the rest of the text still makes sense, and the placeholder mode — [phone] — tells the reader a number was there without showing it.

Do it carefully rather than quickly. A tool that misses one number in a long log has not done the job, and a tool that uploads the text to a server to clean it has created the very exposure it was meant to prevent. Use a tool that runs in the browser, and scan the result for “(” or “+” before you share it. The same care applies to the other contact details that travel with phone numbers: the guide to removing email addresses from text covers the addresses that sit next to them in most exports.

When keeping the phone numbers is the better call

Not every phone number in a block of text is clutter. Sometimes the numbers are the point: if the document is a list of people to reach, deleting the numbers deletes the document’s purpose.

Frequently asked questions

Will removing phone numbers also delete dates and prices?

It should not, if the tool understands phone-number shapes. A good tool matches groupings — area code, exchange, line number, country code — and leaves dates, prices, years and order IDs alone. A plain “remove all numbers” tool will delete them, so test one line with a number, a date and a price before running a long document.

How do I remove UK numbers as well as US ones?

Use a tool that lists UK or international numbers as a feature, or run a second pass for the UK shapes: 07 mobiles, 020 landlines, and the +44 versions of both.

What about numbers with extensions like x123?

The extension belongs to the number, so it should come out with it. Check that the tool handles extensions — look for “ext”, “x” or “extension” in its options — and test it on “Call 020 7946 0958 ext. 123”. If “ext. 123” survives, run a second pass on the extension pattern.

Can Word remove all phone numbers at once?

No. Word has no command that deletes phone numbers from plain text, and Find and Replace cannot match every phone-number shape in one pass. For plain text, use a browser tool.

What is the difference between removing and redacting a phone number?

Removing deletes the number and leaves nothing in its place. Redacting replaces it with a marker like [phone] or [REDACTED], so the reader knows a number was there. Redaction is the right choice when the text is being shared; removal is the right choice when the number is simply clutter.

Closing

Removing phone numbers from text stays a small job as long as three things are decided up front: what counts as a phone number, which mode you are running, and what happens to the spaces afterwards. Pick delete-all for cleaning, a placeholder when the text is being shared, keep-only when the numbers are the thing you want, and masking when the reader needs to know which number is meant without seeing it. Test the tool on one line with a US number, a UK number and an extension before you share the result.