---
title: "Working with Document in Python"
---


{{% alert color="grey" %}}
*Purpose Summary. What is this page about?*

This page describes the Aspose.Words `Document` class for Python via .NET, including its core responsibilities, available properties and methods, and how to create, manipulate, and save documents. It also explains how the `Document` object provides access to sections, mail‑merge functionality, and other document elements.
{{% /alert %}}

The [Document](https://reference.aspose.com/words/python-net/aspose.words/document/) class is central in Aspose.Words. It represents a document and provides various document properties and methods, such as saving or protecting the document. You use the [Document](https://reference.aspose.com/words/python-net/aspose.words/document/) class as the starting point for whatever you want to perform with Aspose.Words: create a new document from scratch, open a template for a mail merge, or get different parts from a document.

The [Document](https://reference.aspose.com/words/python-net/aspose.words/document/) object contains all content and formatting, styles, built-in and custom properties, and the [MailMerge](https://reference.aspose.com/words/python-net/aspose.words.mailmerging/mailmerge/) object that is used for a mail merge. [Document](https://reference.aspose.com/words/python-net/aspose.words/document/) enables you to retrieve text, bookmarks, and form fields for the entire document or separate sections.

[Document](https://reference.aspose.com/words/python-net/aspose.words/document/) contains a collection of the [Section](https://reference.aspose.com/words/python-net/aspose.words/section/) objects enabling you to obtain a particular section or perform some manipulations such as copying or moving sections. The [Document](https://reference.aspose.com/words/python-net/aspose.words/document/) object can be saved at any time to a file or stream and also sent to a client browser.