> For the complete documentation index, see [llms.txt](https://overleaf-pro.ayaka.space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://overleaf-pro.ayaka.space/latex/de/dokumentstruktur/02-table-of-contents.md).

# Inhaltsverzeichnis

In einem LaTeX-Dokument kann das Inhaltsverzeichnis automatisch erzeugt und an einen bestimmten Stil angepasst werden; dieser Artikel erklärt, wie

## Einführung

Das Inhaltsverzeichnis zu erstellen ist unkompliziert, der Befehl `\tableofcontents` erledigt das. Abschnitte, Unterabschnitte und Kapitel sind im Inhaltsverzeichnis enthalten. Um Einträge manuell hinzuzufügen, zum Beispiel wenn Sie einen unnummerierten Abschnitt möchten, verwenden Sie den Befehl `\addcontentsline` wie im folgenden Beispiel gezeigt:

```latex
\documentclass{article}
\usepackage{blindtext}
\usepackage{titlesec}
\title{Sections and Chapters}
\author{Gubert Farnsworth}
\date{ }
\begin{document}

\maketitle

\tableofcontents

\section{Einleitung}

Dies ist der erste Abschnitt.

\blindtext

\addcontentsline{toc}{section}{Unnumbered Section}
\section*{Unnumbered Section}

\blindtext

\section{Second Section}

\blindtext
\end{document}
```

[Öffnen Sie dieses Beispiel in Overleaf](https://www.overleaf.com/docs?engine=pdflatex\&snip_name=Table+of+contents+example\&snip=%5Cdocumentclass%7Barticle%7D%0A%5Cusepackage%7Bblindtext%7D%0A%5Cusepackage%7Btitlesec%7D%0A%5Ctitle%7BSections+and+Chapters%7D%0A%5Cauthor%7BGubert+Farnsworth%7D%0A%5Cdate%7B+%7D%0A%5Cbegin%7Bdocument%7D%0A%0A%5Cmaketitle%0A%0A%5Ctableofcontents%0A%0A%5Csection%7BIntroduction%7D%0A%0AThis+is+the+first+section.%0A%0A%5Cblindtext%0A%0A%5Caddcontentsline%7Btoc%7D%7Bsection%7D%7BUnnumbered+Section%7D%0A%5Csection%2A%7BUnnumbered+Section%7D%0A%0A%5Cblindtext%0A%0A%5Csection%7BSecond+Section%7D%0A%0A%5Cblindtext%0A%5Cend%7Bdocument%7D)

Dieses Beispiel erzeugt die folgende Ausgabe:

![Beispiel eines in LaTeX erzeugten Inhaltsverzeichnisses](/files/cc6a3aa7bc69a272c297459bc3cc6dcfa2b23fb1)

## Den Titel des Inhaltsverzeichnisses ändern

Der Standardtitel des Inhaltsverzeichnisses ist **Inhalt**; er kann in alles geändert werden, was Sie benötigen, wie das folgende Beispiel zeigt:

```latex
\documentclass{article}
\title{Sections and Chapters}
\author{Gubert Farnsworth}
\date{ }
\renewcommand*\contentsname{Zusammenfassung}
\begin{document}
\maketitle
\tableofcontents
\section{Einleitung}

Dies ist der erste Abschnitt.

Lorem  ipsum  dolor  sit  amet,  consectetuer  adipiscing
elit.   Etiam  lobortisfacilisis sem.  Nullam nec mi et
neque pharetra sollicitudin.  Praesent imperdietmi nec ante.
Donec ullamcorper, felis non sodales...

\addcontentsline{toc}{section}{Unnumbered Section}
\section*{Unnumbered Section}

Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
Etiam lobortis facilisissem.  Nullam nec mi et neque pharetra
sollicitudin.  Praesent imperdiet mi necante...

\section{Second Section}

Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
Etiam lobortis facilisissem.  Nullam nec mi et neque pharetra
sollicitudin.  Praesent imperdiet mi necante...
\end{document}
```

[Öffnen Sie dieses Beispiel in Overleaf](https://www.overleaf.com/docs?engine=pdflatex\&snip_name=How+to+change+title+of+table+of+contents\&snip=%5Cdocumentclass%7Barticle%7D%0A%5Ctitle%7BSections+and+Chapters%7D%0A%5Cauthor%7BGubert+Farnsworth%7D%0A%5Cdate%7B+%7D%0A%5Crenewcommand%2A%5Ccontentsname%7BSummary%7D%0A%5Cbegin%7Bdocument%7D%0A%5Cmaketitle%0A%5Ctableofcontents%0A%5Csection%7BIntroduction%7D%0A+++%0AThis+is+the+first+section.%0A++++++%0ALorem++ipsum++dolor++sit++amet%2C++consectetuer++adipiscing++%0Aelit.+++Etiam++lobortisfacilisis+sem.++Nullam+nec+mi+et+%0Aneque+pharetra+sollicitudin.++Praesent+imperdietmi+nec+ante.+%0ADonec+ullamcorper%2C+felis+non+sodales...%0A+++++++%0A%5Caddcontentsline%7Btoc%7D%7Bsection%7D%7BUnnumbered+Section%7D%0A%5Csection%2A%7BUnnumbered+Section%7D%0A%0ALorem+ipsum+dolor+sit+amet%2C+consectetuer+adipiscing+elit.++%0AEtiam+lobortis+facilisissem.++Nullam+nec+mi+et+neque+pharetra+%0Asollicitudin.++Praesent+imperdiet+mi+necante...%0A%0A%5Csection%7BSecond+Section%7D%0A+++++++%0ALorem+ipsum+dolor+sit+amet%2C+consectetuer+adipiscing+elit.++%0AEtiam+lobortis+facilisissem.++Nullam+nec+mi+et+neque+pharetra+%0Asollicitudin.++Praesent+imperdiet+mi+necante...%0A%5Cend%7Bdocument%7D)

Dieses Beispiel erzeugt die folgende Ausgabe:

![Name des Inhaltsverzeichnisses in LaTeX ändern](/files/31b5e25f342602bc21e59425e905110e711655d0)

Die Zeile `\renewcommand*\contentsname{Zusammenfassung}` schreibt "Zusammenfassung" anstelle des Standardwerts. Wenn Sie das Paket verwenden *babel* für [Unterstützung für internationale Sprachen](/latex/de/sprachen/03-international-language-support.md), muss der vorgenannte Befehl innerhalb der geschweiften Klammern von

```latex
\addto\captionsenglish{ }
```

Anstelle von Englisch in `\captionenglish` schreiben Sie den Namen der Sprache, die Sie in babel festgelegt haben.

## Weiterführende Lektüre

Weitere Informationen finden Sie unter:

* [Ein Dokument in LaTeX erstellen](/latex/de/latex-grundlagen/01-learn-latex-in-30-minutes.md)
* [Fett, kursiv und unterstrichen](/latex/de/latex-grundlagen/03-bold-italics-and-underlining.md)
* [Unterstützung internationaler Sprachen](/latex/de/sprachen/03-international-language-support.md)
* [Querverweise auf Abschnitte und Gleichungen](/latex/de/dokumentstruktur/03-cross-referencing-sections-equations-and-floats.md)
* [Indizes](/latex/de/dokumentstruktur/04-indices.md)
* [Glossare](/latex/de/dokumentstruktur/05-glossaries.md)
* [Verwaltung in einem großen Projekt](/latex/de/dokumentstruktur/07-management-in-a-large-project.md)
* [Mehrdatei-LaTeX-Projekte](/latex/de/dokumentstruktur/08-multi-file-latex-projects.md)
* [Hyperlinks](/latex/de/dokumentstruktur/09-hyperlinks.md)
* [Seitennummerierung](/latex/de/formatierung/03-page-numbering.md)
* [Einseitige und doppelseitige Dokumente](/latex/de/formatierung/08-single-sided-and-double-sided-documents.md)
* [Mehrere Spalten](/latex/de/formatierung/09-multiple-columns.md)
* [Zähler](/latex/de/formatierung/10-counters.md)
* [Schriftgrößen, Schriftfamilien und Schriftstile](/latex/de/schriftarten/01-font-sizes-families-and-styles.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://overleaf-pro.ayaka.space/latex/de/dokumentstruktur/02-table-of-contents.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
