Create a Table of Contents in InDesign

For many years, I made the tables of contents for my books manually. I would finish the book and then, one by one, I would open the file for each chapter and write down the name of the chapter, the name of the A Heads, and the page numbers for each. It averaged 200 entries for each book’s table of contents (TOC). It was a tedious process, but manageable.

Thankfully, Adobe has since added an automatic TOC feature to InDesign. Its dialog box is a little confusing, but by following the tips in this article, you’ll master it in no time.

Benefits of the Automatic TOC
There are several benefits to using InDesign’s TOC command:

• InDesign doesn’t make typos. Humans, on the other hand, can easily enter an incorrect page number or entry.

• If anyone makes changes to your documents (a new chapter name or additional pages, for instance), it only takes one click from you to update the TOC.

• When you export a PDF from the document, the page numbers in the TOC are hyperlinked to the actual pages in the document. If you want to go to chapter three, you just click on the page number in the TOC.

• When you create a style for a TOC in the InDesign document, that TOC can be added to an ePub.

Preparing the Document for a TOC
You need a page or two in your document that will hold the TOC. Using the Pages panel, insert those pages (sometimes called front matter) in the front of the book. Then select the page where the TOC will start and choose Numbering & Section Options from the Pages panel menu. In the resulting dialog’s drop-down Style menu (Figure 1), choose the appropriate numeral style (in my case, that’s Roman).

Figure 1. The Numbering & Section Options allow you to set the front matter where a TOC is located to Roman numerals.

Select the page where the main text starts and choose Numbering & Section Options again. Set this to restart at page 1 (Figure 2); that way you can add pages for the front matter without changing the numbers of my main document. I also changed the style to Arabic numerals (Figure 3).

Figure 2. Use the Numbering & Section Options to reset the main document back to page 1 and Arabic numbers.

Figure 3. An example of how the front matter of a document is numbered with Roman numerals while the main body is set with Arabic numbers.

Understanding the TOC Dialog
While the Table of Contents dialog is complicated, you can figure it out with a little exploration.

To begin creating the actual TOC, go to Layout > Table of Contents. This opens the Table of Contents dialog box (Figure 4).

Figure 4. The Table of Contents dialog box at its default settings.

Setting the Title of the TOC
When you first open the TOC dialog box, the Title field default is “Contents.” I change it to the phrase “In this chapter” to describe the TOC entries I have at the front of each chapter in my Visual QuickStart guides. You can insert any word or phrase that makes sense for your book (Figure 5). If you don’t want any description, delete the default entry. It’s very important that you make this — and all subsequent TOC changes — in the TOC dialog box. Any manual modifications you make can cause errors in the automatically generated TOC.

Figure 5 . Fill in the Title field with whatever description you want to head up the TOC.

Setting the Style for the Title
Once you have entered a title for the TOC, you need to format it. Move to the right side of the dialog box and click the Style menu to see a list of paragraph styles in your document (Figure 6).

Figure 6. The Style menu for the Title field of the TOC.

Apply the style for the title. If you haven’t created a style in advance, you can use the New Paragraph Style command at the bottom of the list to create a new style without leaving the TOC dialog box.

Choosing the Entries for the TOC
The entries for each line of your TOC come from the lines of text that have been styled with a certain paragraph style. No paragraph style = no TOC entry. For instance, if you want InDesign to automatically list the pages on which each chapter begins, you must apply a paragraph style to the chapter title, chapter number, or some other paragraph at the start of the chapter. For my books, I tell InDesign’s automatic TOC builder to look for two paragraph styles: one that’s applied to the name of each chapter, and another that’s applied to the A heads (main subsections) of each chapter.

To add paragraph styles as entries in the TOC, simply click the name of the style under Other Styles and then click the Add button (Figure 7). The style appears under Include Paragraph Styles. This indicates that the style will be used as an entry in the TOC.

Figure 7. Click the Add button to move a paragraph style from the Other Styles list to the Include Paragraph Styles. This adds the text formatted with this style to the TOC.

As you click each entry, it appears indented in the Include Paragraph Styles list. Ignore the indents, which are only used under a very esoteric situation that I’ll explore later.

Formatting the Entries
Now that you have the entries listed for the TOC, you need to format them with a paragraph style. Confused? I don’t blame you. You’re choosing the text formatted with a specific paragraph style to be inserted in the TOC, but that text still must have a paragraph style applied to it (Figure 8).

Figure 8. Use the paragraph style list to format entries in the TOC.

The paragraph style for the TOC entry does not need to match the original paragraph style applied to the text in the main part of document. The paragraph style I use for TOC entries is different than the styles I use in running text; for example, the B head in the running text is 14 points, and the B head TOC entries are 10 points. For the sake of clarity, I name the paragraph style within the document as “B head” and the style for the TOC as “B head TOC”.

Viewing all the Setting
Still in the TOC dialog, click the “More Options” button to see all the available controls (Figures 9 and 10).

Figure 9. The abbreviated controls for formatting a TOC.

Figure 10. The complete options available for formatting a TOC.

Page Number Location
Use the Page Number dropdown menu to choose where the page number should appear in relation to the entry: After Entry or Before (Figure 11). You can also choose to omit a page number for the entry, which is helpful if you want to create a list of all illustration captions or photographers in the book, but don’t want to list the pages on which they appear.

Figure 11. Use the Page Number menu to choose where the page number should be located or if you should have a page number at all.

Styling the Page Number
Once you’ve set a location for the page number, you set a character style for the number (Figure 12). This makes it possible to style the number with a color, italic text, or some other indicator.

Figure 12. Use the Style list to the right of the Page Number menu to apply a character style to the page number.

Separating the Entry and Page Number
TOCs need a divider to separate an entry from its page number. The default is a tab character, written as ^t. You can use the drop-down menu to choose a special character, such as an em dash, forced line break, and so on (Figure 13). My favorite is to change the tab to a right indent tab (^y). This forces the page number all the way to the right side of the margin.

Figure 13. The special characters you can insert between the entry and the page number.

Understand, though, that adding a character between the entry and the number does not create a tab leader. The tab leader comes from the tab created as part of the paragraph style applied to the entry.

You’re not limited to the items in the special character dropdown menu: You can insert your own! Say you want a colon after each entry. You simply insert the colon before the tab character so the field reads “:^t”. This adds the colon after the entry. You can also get fancy with the entry between the entry and the page number and type text, such as “On Page”.

Styling the Separator
Just as you can apply a character style to the page number, you can also apply a character style to the separator between the entry and the page number. This isn’t important if your separator is invisible, such as a tab or space. But if a tab leader is part of the paragraph style, you may want to apply a character style that makes the leading periods smaller (Figure 14).

Figure 14. Use the Style list to apply a character style to the separator between the entry and the page number.

Looking at the Levels
Perhaps the most misunderstood section of the TOC dialog box is the setting for Levels. When you add each paragraph style to the Include Paragraph Style, it’s indented from the previous entry (Figure 15). That’s because the levels are automatically set to indent the next style.

Figure 15. The indents for entries automatically appear as each paragraph style is added to the list.

However, except in two very specific circumstances, the levels are there solely for display in the dialog box. They don’t affect anything in an ordinary TOC. You can leave the entries indented or you can change them using the Levels control (Figure 16).

Figure 16. Use the Levels control to set the indents for each entry.

Levels don’t do anything to the actual TOC unless the entries are sorted alphabetically (see the next section). In that case, the entries are sorted by alphabetically within each level. Levels are also used when the TOC style is applied as part of an export to ePub.

Sorting Entries
Most of the time, you want TOC entries to appear in the same order they appear in the document: by page number. However, some TOCs don’t need page numbers, such as those that list all the photographers or illustrations in a document. In these cases, you might want the entries to be listed alphabetically. That’s where the Sort Entries in Alphabetical Order comes in (Figure 17).

Figure 17. Use Sort Entries in Alphabetical Order to list the items in the TOC in alphabetical order.

Apply the Settings for Each Entry
This may seem like a lot of work, and you’re not done yet: You must repeat it for each paragraph style in the document text that you want to show up as a TOC entry. This is probably the most common mistake made in creating a TOC: You set up all the options for one entry, but forget to set it for the others.

Go back to the Include Paragraph Styles area, select a new style, and set all the options (Figure 18).

Figure 18. Each entry in the TOC needs to be set by the Style options. Here the options for the B head have been set.

Setting the Options
The Options settings (Figure 19) are pretty straightforward.

Figure 19. The Options area for the TOC dialog box.

Create PDF Bookmarks creates the bookmark navigational aids in the exported PDF.

Replace Existing Table of Contents allows you to make changes to an existing TOC.

Include Book Documents is available only when the book that contains the open document is open. This setting is important if you want to create a TOC for all the documents in a book.

Run-in puts all the entries in a single paragraph. Each entry is separated by a semicolon and a space.

Include Text on Hidden Layers includes entries from layers that are hidden in the Layers panel. The benefit of this setting is you can include items such as advertisers or photographers that you don’t want to appear in the main body of the document.

Working with Numbered Paragraphs
There’s a slight twist to working with numbered paragraphs. Most people don’t want those paragraph numbers in a TOC. The Numbered Paragraph drop-down menu lets you tell InDesign how to treat them (Figure 20).

Figure 20. Use the Numbered Paragraphs menu to control how numbered paragraphs are handled.

Include Full Paragraph uses both the number and the text for the paragraph.

Include Numbers Only uses just the number for the paragraph.

Exclude Numbers drops the numbers from the TOC and includes just the text for the paragraph.

Saving as a TOC Style
You can save all these settings you’ve been slaving over by clicking the Save Style button. This opens a dialog box where you can name the style so all these settings are maintained in the document. Then you choose that TOC style when you create a new TOC for the document (Figure 21).

Figure 21. A saved TOC style appears in the TOC Style list.

If you save a TOC style for your document, you have the option when exporting as an ePub to use that TOC Style to create a TOC for the ePub. You don’t have to create a TOC for the document. You just need a TOC style.

The Big Payoff: Automatic Updating
After all this work, you need a big benefit. If you (or anyone else) has made any changes to the main body of your work — text, page numbers, order of items, or paragraph and character styles — simply put your insertion point in the text frame that holds the TOC and choose Layout > Update Table of Contents. The text updates automatically.

Posted on: January 26, 2012

Sandee Cohen

Sandee Cohen is a New York City-based instructor and corporate trainer in a wide variety of graphic programs, especially the Adobe products, including InDesign, Illustrator, Photoshop, and Acrobat. She has been an instructor for New School University, Cooper Union, Pratt, and School of Visual Arts. She is a frequent speaker for various events. She has also been a speaker for Seybold Seminars, Macworld Expo, and PhotoPlus conferences. She is the author of many versions of the Visual Quickstart Guides for InDesign.

18 Comments on Create a Table of Contents in InDesign

  1. I really do not understand who’s idea is to set Entry Style: to [Same Style] as default and Page Number: After Entry, that’s craziest thing inside InDesign. Who want this styles for defaults, and ^y is very descriptive and easy to understand and remember, I hope this will be fixed in next version.
    Bojan Živković

  2. Thanks for a great, in-depth article on TOC! I truly appreciate your “voice of experience extras.”

  3. Thanks for a great, detailed article Sandee! — James Wamser

  4. Is there a way to make TOC work for a magazine? None of my headings are standardized styles. I initially design them in a “setup” document and then redesign them to fit the space available once I move them into the actual magazine layout. The TOC page, though, is standardized and divided into sections like Parenting, Health & Beauty, Community, etc. I wonder if a hidden layer would help.

  5. A few years ago I did a book with a serial TOC and an alphabetical TOC. It was dumb luck that I discovered one could do an alphabetical TOC.

    Generally, advice I would give, based on my several failed attempts at creating TOCs: Before you begin your book, decide on a unique style for whatever you want in the TOC. I didn’t do that once and photo captions became part of my TOC. It’s better to decide in advance than revamp later.

  6. It seems too complicated. I couldn’t apply it after reading your article over and over. Now I will stay with manual TOC. Thanks though!

  7. This is an extremely clear and well written tutorial.
    It made something that could have taken me a long time to work out, very simple and I was up and running in minutes.

    Once again, thank you so much.

  8. Your instructions are very helpful. However, now that I have a Catalog designed using the Master Pages for each of my documents to hold the Section, Chapter Name and Chapter Subname, the later 2 are included in a banner at the top of the page, I cannot get the TOC to recognize these paragraph styles in the document and then use them in the TOC, is there an automated way to accomplish this or must I revert to doing those pieces manually after the rest of the TOC has been generated?

    Thanks for you help.


  9. Lets say you go through all this trouble to create an exact TOC, then want to export it to use in another document. What are your options?

  10. One thing I’m having BIG trouble with, is getting the links to work when exporting to epub.

    The table looks fine, but when an entry is clicked on it does not go to the page, but stays on the table of contents page. Muli page contents goes to the first page of the contents. all this is in CS6. Quite fustrating!

  11. Patricia Estall

    August 19, 2013 at 5:47 pm

    I’m tearing my hair out trying to create my first automatic TOC. I’m almost there, except that some of my chapter headings run on two lines. These chapters run the entire chapter title across the page and disturb the page number. So…how to break these particular two line chapter headings. Also, my Contents (left to read the word Contents) is causing me problems. In the TOCCaption style I added a paragraph rule under the word Caption to cross the text and I gave it a 1p0 Space After. What I’m getting is a line across the width of the page and almost as an underscore with no space after. I would be grateful for anyone’s advice. Thank you.

  12. Can anyone answer either of these two questions?

    1. Is there a way to create three different TOC’s for items appearing in a catalog (not just chapter starting points)? 

    I need to display some index information alphabetically in one instance and sort separately on two other item criteria.

    2. Is there a way to display a page range that certain items appear? 

    An example would be where the same item appears on pages 3-9. It may be acceptable for it to list as appearing on pages 3, 4, 5, 6, which I thought was how the “Run-in” setting would list them. But they are all separated out by semicolons one item and one page number at a time instead of being grouped together. (For example, Item 1 page 1; Item 1 page 2; Item1 page 3) 

    Perhaps there is a way to do this in InDesign but not using the Table of Contents feature?

  13. This tutorial is OK, and I noticed this across this site, you guys just type the instructions inside the paragraph. To make it a lot easier, you should bullet or number each step, people get lost in the instructions even though there are pictures, it’s too much text to read

    1. Click this

    2. Select this.

    3. Hit Ok

    4. Click New

    Less typing for you, less reading for everyone else.

  14. every epub TOC i create now, for some reason, ends up with the page number displaying on the left side and the chapter title on the right side. is there any styling or something i’m doing wrong that results in this flipped formatting?

  15. I want the navigational TOC words to be different than chapter titles, and so I have created a style that outlines what I want it to say, and placed it on hidden layer.  On export, it does not show up, and all of the navigational TOC entries have dashes between the words.  If the “hidden” layer is showing, then on export the navigational TOC is perfect.  Can anyone help?


  16. Nice, but wish it would have included clear instructions on how to insert a TOC that spans more than one spread.

  17. Sandee: I took a Quark class with you at The New School way back in the computer dark ages of the 20th century, and here you are saving my ass again 30 years later!!! You were already fabulous then, and you’re still fabulous now. This is a terrific article. Thank you very much! Janice

  18. OMG Thank you!

Leave a comment

Your email address will not be published.