AbraCalc

Extract Numbers from Text

Pull out all numbers (integers and decimals) from any block of text.

Embed this tool on your site
Cite this tool

APA

AbraCalc. (2026). Extract Numbers from Text [Online calculator]. Retrieved from https://abracalc.com/text/extract-numbers/

BibTeX

@misc{abracalc-extract-numbers, author = {AbraCalc}, title = {Extract Numbers from Text}, year = {2026}, howpublished = {\url{https://abracalc.com/text/extract-numbers/}} }

Did this tool answer your question?

How to use this tool

  1. Enter text in the fields above.
  2. Results update instantly as you type — or click Calculate.
  3. Read your extracted numbers and the full breakdown beneath it.

Pull out all numbers (integers and decimals) from any block of text.

How it works

This tool scans any block of text and extracts all numeric values -- both integers and decimal numbers -- returning them as a clean list. It is ideal for quickly pulling figures out of reports, emails, tables, or mixed-format documents without manual copying.

The extractor uses pattern matching to find sequences of digits, including those with a decimal point. It recognizes values like 42, 3.14, and 1000 embedded anywhere in a sentence and collects them in order of appearance.

Paste your text into the input and the extracted numbers appear instantly in a list. You can then copy them into a spreadsheet, calculator, or code editor for further processing. This avoids the tedium and typos that come with manual extraction from long documents.

Numbers formatted with commas as thousands separators (e.g. 1,234,567) may be returned as multiple separate numbers (1, 234, 567) depending on the implementation, so check the output format if your data uses comma-formatted figures.

Worked example

Extract prices from a product description

  1. Paste: 'Item A costs $12.99, Item B is $5, and the bundle is $15.50.'
  2. The tool identifies: 12.99, 5, 15.50
  3. These are returned as a list.
  4. Copy the list into a spreadsheet to sum them.

12.99, 5, 15.50

Common mistakes to avoid

  • Pasting text with comma-formatted numbers like '1,000,000' and expecting a single value -- commas may cause it to be split into '1', '000', '000'.
  • Assuming percentages or currency symbols are included in the extracted value -- symbols like $ or % are stripped, leaving only the digits.
  • Not reviewing extracted numbers from scientific notation (e.g. '2.5e10') -- the result may appear as two separate numbers: '2.5' and '10'.

Key terms

Integer
A whole number with no decimal part, e.g. 7 or 1042.
Decimal number
A number that includes a fractional part separated by a decimal point, e.g. 3.14 or 0.5.
Pattern matching
A technique that searches text for sequences matching a defined pattern, such as one or more digits optionally followed by a dot and more digits.

Frequently asked questions

Does it extract negative numbers?
Yes — numbers preceded by a minus sign are included.

References & sources