> For the complete documentation index, see [llms.txt](https://docs.overleaf.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.overleaf.com/navigating-in-the-editor/selecting-and-managing-files.md).

# Selecting and managing files

You can view the logical structure of your `.tex` file using our File Outline feature. This displays most standard LaTeX sectioning elements in a sidebar to allow quick navigation within the open `.tex` file. The File Outline is displayed at the bottom of the left pane, which also contains the file tree.

<figure><picture><source srcset="/files/q9zW23rlYP0b0iIKEEcu" media="(prefers-color-scheme: dark)"><img src="/files/O3l62TQ27ORsskZLYIpN" alt="The location of the File Outline in the Overleaf Editor (under File Tree)"></picture><figcaption></figcaption></figure>

This feature displays the outline for the file you have open in the editor, not your entire project. If you have a multi-file project, a new outline will be displayed when you open a different file in the editor.

{% hint style="info" %}
Note that the File Outline doesn't currently display section headings included via `\input`, `\include` or `\import` commands.

One workaround for this is to use these commands after a [supported heading command](#supported-heading-commands). For example, using `\chapter{Chapter One}` or `\include{chapter1.tex}` will display "Chapter One" in the file outline, instead of just using `\include{chapter1.tex}`, which is not displayed in the File Outline.
{% endhint %}

## Expanding and collapsing the File Outline and File Tree

Use the caret to the left of "File Outline" or "File Tree" to expand or collapse the area. You can also resize the File Outline by clicking and dragging the handle up or down.

<figure><picture><source srcset="/files/asKwp1fiWOoHUHmhLOvi" media="(prefers-color-scheme: dark)"><img src="/files/4Oc8whMOkxHea3F8hbF3" alt="Demonstration of how to expand and collapse the File Tree and File Outline" width="128"></picture><figcaption></figcaption></figure>

## Navigating within your files using the File Outline

With longer `.tex` files, you may want to quickly jump to another section heading within the file. The File Outline feature allows you to do this. Click on the heading you'd like to jump to, and the cursor will move to that heading in the editing pane. The selected heading will be highlighted in the file outline list for reference as you're editing the file.

## Supported heading commands

The File Outline feature supports the standard [LaTeX section heading commands](https://www.overleaf.com/learn/latex/Sections_and_chapters#Document_sectioning):

* `\book` (from the memoir document class)
* `\part` (for book and report document classes)
* `\chapter` (for book and report document classes)
* `\section`
* `\subsection`
* `\subsubsection`
* `\paragraph`
* `\subparagraph`

Starred variants of these commands for unnumbered headings are also supported.

{% hint style="success" %}
If your `.tex` file doesn't contain every heading level, that's no problem; the File Outline will display your file's structure according to the heading levels that we detect within the file.
{% endhint %}

{% hint style="warning" %}
The File Outline feature doesn't run a full LaTeX engine, so not all LaTeX commands within section headings are supported.

In particular, the expansion of custom macros and math mode content won't be rendered in the File Outline list. Other non-standard usages, like multiple `\label`s following a sectioning command, or sectioning commands broken across multiple source lines, also won't be detected by the File Outline in all situations.
{% endhint %}


---

# 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://docs.overleaf.com/navigating-in-the-editor/selecting-and-managing-files.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.
