> 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/formatting/08-single-sided-and-double-sided-documents.md).

# Single sided and double sided documents

## Introduction

LaTeX is shipped with a number of “standard” classes which can be used for creating different types of document, including: `article`, `book`, `report`, `letter`, `slides` and `proc` (for conference proceedings). LaTeX also provides the `minimal` class for debugging purposes or as a basis for writing your own class file. Many additional document classes are published in the [Overleaf template Gallery](https://www.overleaf.com/latex/templates), or can be [downloaded from CTAN](https://ctan.org/topic/class).

## Creating two-sided documents

To create a two-sided document pass the `twoside` option to the `\documentclass` declaration; for example:

```latex
\documentclass[twoside]{article}
```

**Note**:

* The `book` class is two-sided by default so you do not need to add the `twoside` option.
* The `slides` class does not support the `twoside` option—perhaps because it would not make sense for presentation slides to do that.

### Overleaf example to explore document layout

The following example provides a small Overleaf project which uses the `layout` package to create graphics that show the initial (*default*) document layout for your preferred document class. Those default values can be changed by loading packages, such as `geometry`, which change the default values of LaTeX's page-layout parameters. See the articles [Page size and margins](/latex/formatting/07-page-size-and-margins.md) and [A visual guide to LaTeX’s page layout parameters](/latex/in-depth-articles/04-a-visual-guide-to-latex-s-page-layout-parameters.md) for further information.

For two-sided documents, the `book` class, and others using the use the `twoside` option, the example will create separate graphics for the left-hand and right-hand pages. On opening the project you’ll see the left- and right-hand pages for `\documentclass[twoside]{article}`.

```latex
% Choose the document class whose layout you want to visualize: uncomment
% the one you want, comment out the others.
% \documentclass[a4paper]{article} %Produces one page (based on A4 paper size)
% \documentclass[a4paper]{report} %Produces one page (based on A4 paper size)
% \documentclass[twoside,a4paper]{report} %Produces two pages (based on A4 paper size)
% \documentclass[a4paper]{book} %Produces two pages (based on A4 paper size)
% \documentclass[a4paper]{letter} %Produces one page (based on A4 paper size)
% \documentclass[twoside, a4paper]{letter} %Produces two pages (based on A4 paper size)
\documentclass[twoside,a4paper]{article} %Produces two pages (based on A4 paper size)
\usepackage{layout}
\begin{document}
\layout
\end{document}
```

[Open this project to explore the layout of standard LaTeX document classes.](https://www.overleaf.com/docs?engine=pdflatex\&snip_name=document+class+layout\&snip=%25+Choose+the+document+class+whose+layout+you+want+to+visualize%3A+uncomment%0A%25+the+one+you+want%2C+comment+out+the+others.%0A%25+%5Cdocumentclass%5Ba4paper%5D%7Barticle%7D+%25Produces+one+page+%28based+on+A4+paper+size%29%0A%25+%5Cdocumentclass%5Ba4paper%5D%7Breport%7D+%25Produces+one+page+%28based+on+A4+paper+size%29%0A%25+%5Cdocumentclass%5Btwoside%2Ca4paper%5D%7Breport%7D+%25Produces+two+pages+%28based+on+A4+paper+size%29%0A%25+%5Cdocumentclass%5Ba4paper%5D%7Bbook%7D+%25Produces+two+pages+%28based+on+A4+paper+size%29%0A%25+%5Cdocumentclass%5Ba4paper%5D%7Bletter%7D+%25Produces+one+page+%28based+on+A4+paper+size%29%0A%25+%5Cdocumentclass%5Btwoside%2C+a4paper%5D%7Bletter%7D+%25Produces+two+pages+%28based+on+A4+paper+size%29%0A%5Cdocumentclass%5Btwoside%2Ca4paper%5D%7Barticle%7D+%25Produces+two+pages+%28based+on+A4+paper+size%29%0A%5Cusepackage%7Blayout%7D%0A%5Cbegin%7Bdocument%7D%0A%5Clayout%0A%5Cend%7Bdocument%7D)

This example produces graphics such as those shown in the following image. Note that the image below has been cropped/edited for clarity of presentation in this article.

![Image showing latex document layout](/files/FTsf5epehjONwheEqXlx)

## Further reading

* [`geometry` package documentation](https://ctan.org/pkg/geometry?lang=en)
* [A visual guide to LaTeX’s page layout parameters](/latex/in-depth-articles/04-a-visual-guide-to-latex-s-page-layout-parameters.md)
* [Page size and margins](/latex/formatting/07-page-size-and-margins.md)
* [Footnotes](/latex/formatting/14-footnotes.md)
* [Margin notes](/latex/formatting/15-margin-notes.md)
* [Headers and footers](/latex/formatting/02-headers-and-footers.md)
* [Sections and chapters](/latex/document-structure/01-sections-and-chapters.md)
* [Management in a large project](/latex/document-structure/07-management-in-a-large-project.md)
* [Multi-file LaTeX projects](/latex/document-structure/08-multi-file-latex-projects.md)
* [Text alignment](/latex/formatting/06-text-alignment.md)
* [Font sizes, families, and styles](/latex/fonts/01-font-sizes-families-and-styles.md)
* [Inserting Images](/latex/more-topics/27-inserting-images.md)
* [Positioning images and tables](/latex/figures-and-tables/02-positioning-images-and-tables.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/formatting/08-single-sided-and-double-sided-documents.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.
