# How to add a section* to the list of contents, but without giving it a number? [duplicate]

I have several section* 's in my LaTex text. But I only want the first one (abstract) to appear in the list of contents, although without a number. All the other section* 's are just a few subheadlines which should not appear anywhere and also don't have a number so far, which is good. Is there any exception regulation for this case only?

## marked as duplicate by Marco Daniel, Dror, lockstep, Svend Tveskæg, karlkoellerJan 31 '14 at 12:48

• \addcontentsline{toc}{section}{Abstract} – Steven B. Segletes Jan 31 '14 at 12:19
• Which documentclass? If you use KOMA you can use \addsec – Marco Daniel Jan 31 '14 at 12:19
• Are you sure you want to use \section* and not something like \paragraph? – Dror Jan 31 '14 at 12:20

KOMAscript solution:

\documentclass{scrartcl}
\newcommand{\Section}[1]{%
\section*{#1}
}

\begin{document}
\tableofcontents
\Section{Abstract}
\begin{abstract}
This is my abstract
\end{abstract}
\section{First section}
This is my text.
\end{document}


In older versions of KOMAscript and with other document classes you’d probably have to use \addcontentsline instead of \addxcontentsline (note the x), or load \usepackage{tocbasic}. As far as I know the only difference is whether the option numberline is supported for unnumbered TOC entries.

Other than that this answer has been given before.

You can also try something like this:

\begin{document}

\tableofcontents{
}

\section*{Abstract}

\section*{First Section}

\section*{Second Section}

\end{document}


Which has this output:

• Yes, this works, but I want to have all the other section* 's I used so far not to do the same, like they should not be in the list of content. So it's just for this one exception! – UserSoUndSo Jan 31 '14 at 15:14