Display Line Numbers in InDesign

This script enhances InDesign’s feature-set. You can now add line numbers to your InDesign pages.

New! Version 3.6 Now Released!

  • New feature: You now have the option to count paragraphs in addition to the standard option of counting lines.

New! Version 3.5 Now Released!

  • New feature: Choose what number to start numbering at – so if your document is divided into two or more files, you can now number the entire document consecutively throughout.

Main Features

  • Add line numbers to selected paragraph styles only.
  • Add numbers at user-selected intervals: 5 … 10 … 15 … 20 or 3 … 6 … 9 … 12 etc.
  • The line numbers are placed in a text frame with their own object style, and the line numbers are given their own paragraph style – so you can quickly and easily change all aspects of the line-number formatting.
  • Optimized for speed.


  • Add line numbers to your book design. Poetry, academic editions of classic texts, and many other books require line numbers in the margins. This script gives you all the flexibility you need to easily add such numbers.
  • As a book designer, you may often receive corrections from authors and editors that say something like: “23rd line from bottom, please add a comma.” With this script you can speed things up, as InDesign will now display line numbers besides each line (see screenshots below). The Display Line Numbers script can add line numbers to a single text frame, or to an entire story.

How To Use the Script

In the script dialog box (shown below), select whether you wish to add numbers to the entire document, the current story, or the selected text frame only.

Choose whether you wish to add numbers to each line or at intervals (between 1 and 20) – simply select your desired interval from the dropdown menu.

Choose whether you would like the numbering to restart on each page, or whether an entire story should be renumbered consecutively.

Choose where you’d like the numbers to be placed. There are 3 options in the dropdown menu: “Outside Margin” will place the numbers in the left margin on a left-hand page, and in the right margin on a right-hand page. The other two options will force the numbers to always be placed in the left or right margin, respectively, regardless of which page they appear on.

Choose which paragraph styles you’d like to number: double-click on a paragraph style in the list on the left to select/deselect it, or use the “Select All” and “Deselect All” button at the bottom of the list.

If you are using consecutive numbering (that doesn’t restart at 1 on each page), enter the number you would like numbering to commence at in the “Start at” field.

Finally, you can choose to restart the numbering whenever the script reaches a certain paragraph style. For instance, in a book of poetry, you may want the numbering to restart whenever the script reaches a paragraph style called “Poem Title” so that the numbering in each poem restarts at 1. To do this, select the desired paragraph style in the list, and click on the Restart button. The paragraph style will be marked with a {RESTART} tag in the list (for an example, see screenshot below). To remove the tag, simply click on the Restart button again.

Line Numbers InDesign Script Id-Extras.com

Once you have set all the options (which are stored with the document so it is not necessary to set them more than once) simply click on the Replace Numbers buttons. You may also click on the Add Numbers buttons. The difference between these two buttons is as their name suggests: The Replace Numbers button will delete any existing line number frames before applying the new line numbers, whereas the Add Numbers button will simply add a new set of numbers on the page and not delete any previous number frames. Although this behavior can be useful on occasion, you will normally want to use the Replace Numbers button because this avoids inadvertently creating two sets of line numbers on the same page.

To remove numbers from the document, you can click on the Remove Numbers button. Alternatively, you can delete the special layer created by the script (in the Layers panel) to remove all the line numbers throughout the document.


  • To choose the distance you would like the numbers to be from the main text frame, there are two options:
    (1) Via the Line Numbers Object Style. Edit the style: Under the Text
    Frame General Options tab, modify the value of the Right (or Left) Inset
    Spacing field as needed.
    (2) Via the Line Numbers Paragraph Style. Edit the style: Under the
    Indents and Spacing tab, modify the value of the Right (or Left) Indent
    field as needed.
  • Hover the mouse of many of the controls in the dialog box to see a brief explanatory note.

For the technically minded: The script adds a new text frame or text frames alongside the selected frames. In this new text frame it adds the line numbers. The new text frame is placed on a special layer created by the script. The script creates an object style which is applied to the numbers text frame, as well as a paragraph style which is applied to the numbers paragraphs. A new RGB swatch is also created.

You can download a demo version of this script here.

A single license for this script is available at $49 USD. For multiple licenses, please contact us to arrange a discount.

The terms of the license permit the installation of the script on a single user’s computer. The script is copyright. It is illegal to make unauthorised copies of the script.

To purchase the full version for only $49, click the “Buy Now” button, or email us. Your will receive your full, unlocked script normally within one working day.

Add Line Numbers to InDesign


Add Line Numbers to InDesign


Buy Now

“… not only a great time-saver for us, but also a guarantee that the numbering is rightly done and error-free, and this is priceless!”


Buy Now

Display Line Numbers: $49.00

For multiple licenses (5 or more), please contact us to arrange a discount.



System Requirements

  • InDesign CS4 or higher
  • Windows or Mac computer

Trial Download

Click the button to download a demo version of “Line Numbers.”

Your thoughts here
  1. Very disappointed, downloaded the demo and the script will not run without a serial number.

  2. Kerri, thanks for pointing out this mistake! I’ve updated the link. So please go ahead and download the demo file again from this page. Delete the previous version, and install the new version of the demo to your InDesign scripts folder. You should now be able to run the script demo without it asking for a serial number. If you have any difficulties, feel free to get in touch.

Trackbacks for this post

  1. […] Line Numbers […]

Leave a Reply

WordPress Video Lightbox