Modern Niche World MNW

Add Line Numbers

Paste text to put a number at the start of each line, with your choice of start, step, separator and padding, or take the numbers off lines that already have them.

Paste or type up to 5 MB and 500,000 lines. It stays on this page: nothing is sent anywhere or saved.

What to do

A whole number from 0 to 999,999,999.

From 1 to 1,000,000: 10 gives 10, 20, 30.

Paste text above to number its lines.

Everything happens on this page, on your device: your text is never sent anywhere or saved.

Number the lines of any text

Line numbers make it easy to point to one line of a poem, a script, a list of steps or a block of code: “see line 12”. Paste your text, choose how the numbers look, and copy the result. Copied some numbered text and only want the words? The same page takes the numbers off.

How to use it

  1. Paste or type your text, up to 5 MB and 500,000 lines.
  2. Choose Add numbers or Remove numbers.
  3. Set the separator and, when adding, the start, step and padding. The result updates as you type.
  4. Copy the result, or download it as a .txt file.

The options

  • Start at and Step: start anywhere from 0, and count up by 1, by 10 or by any whole number up to 1,000,000.
  • Separator: what goes between the number and the line: a period, a parenthesis or a colon with a space after it, a tab, or a single space. With a tab, a spreadsheet you paste into can put the numbers in a column of their own.
  • Padding: zeros (01, 02 … 10) or spaces make every number as wide as the largest, so the lines start in one column.
  • Skip empty lines: blank lines stay blank and don’t use up a number, as in a poem with verses. Lines holding only spaces count as blank.

Removing numbers

A number at the start of a line, followed by the separator you choose, comes off, along with any spaces padding put before it. A line holding only a number and a period, parenthesis or colon becomes empty. Lines that don’t start that way stay exactly as they were, and the message says how many there are.

Good to know

  • Numbers are plain digits, with no commas, even past 999.
  • A line break at the very end of your text stays, and doesn’t get a number.
  • Numbering again? Remove the old numbers first, with the same separator, then add new ones, so no line ends up with two numbers.
  • Only numbers change. This page never moves, sorts or edits your lines. To put them in order first, use Sort Lines; to tidy spaces and empty lines, use the Text Cleaner.
  • Nothing leaves your device. The text is never sent anywhere or saved.

Frequently asked questions

How do I start at 0, or count in tens?
Type 0 in Start at to begin at zero. To count in tens, type 10 in both Start at and Step, which gives 10, 20, 30 and so on. Any whole number works, from 0 to 999,999,999 for the start and from 1 to 1,000,000 for the step.
What does padding do?
It makes every number as wide as the largest one, so the text after the numbers starts in one column. With zeros, 1 to 10 become 01 to 10; with spaces, a space goes before 1 to 9 instead. The lines only look even in a font where every character is the same width, such as the one in the boxes here.
Will Remove numbers take off numbers that belong to my text?
Only a number at the very start of a line, followed by the separator you choose, comes off. With a period or a colon chosen, lines such as 3.5 kg of flour or 10:30 start stay as they are. With Space chosen, any line that starts with a number and a space loses it, as in 2024 was a good year, so choose the separator your numbers really use.
Is my text sent anywhere or saved?
No. The numbers are added and removed by this page’s own code, on your device, and nothing is sent, logged or saved. Reloading the page clears it, so copy or download the result first.