TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've tried adapting the answer here, to make invisible subsections by changing 'section' to 'subsection' everywhere. It didn't seem to work. Basically, what I want is to have subsections that appear in the bookmarks menu of adobe (or other pdf readers) so that I can't jump to their location, but they shouldn't appear in the text itself. Ideally I would prefer these subsections (or sections for that matter) didn't interfere with the numbering of regular subsections, but that's the less important part.

share|improve this question
up vote 2 down vote accepted

You want to use the command \addcontentsline to add something to the table of contents.

\section{You can see this section}

\addcontentsline{toc}{subsection}{You can't see this one}

\subsection{You can see this one!}


This will put an unnumbered entry at the level of subsection into the \tableofcontents and and entry in the index! More information can be found here.

share|improve this answer
very good! Thank you, Nethanael. Is it too much to ask that the tex editor (TeXstudio) recognize it too? :) – giladrv Feb 8 '13 at 9:24
You could make an actual invisible subsection, which would probably be recognised by TeXstudio, but that would be much more than a line long! I think I have some code at home that could work, I'll give it a look later. Still, one line answers are usually the best! – Nathanael Farley Feb 8 '13 at 10:18

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.