Line Numberer

Add line numbers to any block of text instantly in your browser. Free online line numberer — useful for code, logs, and scripts.

Loading calculator…

Results

Numbered lines
DetailValue
Lines

What is this calculator for?

Prefix each line with a number for easy reference in code, logs, and documents.

How to Use This Calculator

Enter the values below, then press Calculate (or press Enter). The calculator updates your results instantly. Try different values to see how your inputs change the outcome.

  1. Text — enter a value. A typical Text would be Paste code, logs, or content here….
  2. Start at — enter a numeric amount.
  3. Pad numbers to equal width — enter a yes/no option.
  4. Review your results — the key output is highlighted, with supporting figures below.

What You'll Need

Text
a value · required
Start at
a numeric amount range 1–∞ · optional
Pad numbers to equal width
a yes/no option · optional

About This Calculator

This tool splits your text by lines and prefixes each with its index, starting from the number you choose.

You can optionally pad the numbers to equal width so the columns align neatly. Everything runs locally in your browser.

Worked Examples

Example

1: alpha 2: beta 3: gamma

Frequently Asked Questions

Can I start numbering from a number other than 1?
Yes — set the "start at" value to begin from any whole number, useful when continuing a previous sequence.
Does it handle empty lines?
Yes — blank lines are preserved and still get a number, so the line count always matches your original text exactly.