Skip to content

.RST file extension

To open .RST files on Windows, open the .rst file in a text editor (for example, Notepad) to view or edit the raw reStructuredText.

To open a .rst file, start with a plain-text editor (it is usually reStructuredText). If you want it formatted (headings, lists, links), use a reStructuredText-capable tool such as Docutils or Sphinx.

Last updated: June 10, 2026

Open on your device

Choose your operating system for a dedicated step-by-step opening guide.

How to open .RST files

Use these platform-specific instructions to open .RST files safely.

Windows

  1. Open the .rst file in a text editor (for example, Notepad) to view or edit the raw reStructuredText.
  2. If you need formatted output, use Docutils or Sphinx tools to render/build it (for example, convert to HTML).
Full Windows guide

Mac

  1. Open the .rst file in a plain-text editor (for example, TextEdit in plain-text mode) to view or edit it.
  2. For formatted viewing, render it with Docutils or build it with Sphinx on your Mac.
Full Mac guide

Linux

  1. Open the .rst file in any text editor to view or edit the markup.
  2. To see formatted output, render it with Docutils or build documentation with Sphinx.
Full Linux guide

iOS

  1. In the Files app, open the .rst file in a text editor app that supports plain text; if you need formatted output, transfer it to a desktop and render it with Docutils/Sphinx.
Full iOS guide

Android

  1. Open the .rst file in a text editor app to view or edit the plain text; for formatted rendering, transfer it to a desktop and use Docutils/Sphinx.
Full Android guide

Security notes

  • .rst is plain text, but be cautious when rendering: reStructuredText supports directives, and building with documentation tools can process external references or include content depending on tool configuration.
  • Only run Docutils/Sphinx builds on .rst content you trust, especially if the project configuration or build process can pull in or include additional files/resources.
  • If a .rst file is embedded in a larger project, review build scripts and configuration (for example, Sphinx settings) before executing any automated build steps.

Can't open this file?

These are the most common causes and fixes when .RST files fail to open.

Common reasons

  • The file opens as plain text and looks “unformatted”
  • Double-clicking does not open the file or opens in the wrong app
  • Rendering/build fails due to syntax or directive errors
  • Text displays with strange characters or wrong line breaks

Fix steps

  1. Open it in a text editor for reading/editing the source.
  2. If you want a styled view, render/convert it using Docutils or build it using Sphinx to produce HTML (or another output format).

Recover a deleted or lost .RST file

If the file was deleted by mistake or the drive was formatted, data recovery software may be able to get it back. Stop writing to that drive right away, because new data can overwrite what you want to recover.

We may earn a commission when you use affiliate links. This supports our free file extension guides.

What is a .RST file?

.rst typically contains reStructuredText markup, a lightweight plain-text markup language. It is widely used in the Python ecosystem (including docstrings) and is the default source format for Sphinx documentation. Common MIME types include text/x-rst (as used in the freedesktop.org shared MIME database) and the IANA-registered text/prs.fallenstein.rst.

Background

reStructuredText (reST) is a plaintext markup format designed for writing structured documents that can be converted into formats like HTML and others via tooling such as Docutils. It uses readable, text-first syntax for sections, lists, code blocks, links, and more, making it friendly to version control and code review.

In practice, .rst is strongly associated with Python documentation workflows: Sphinx uses reStructuredText as its default markup and builds documentation sites from .rst sources, while Docutils provides the core parsing and transformation machinery. reStructuredText is also used as a standard structured docstring format in the Python community (PEP 287).

Because .rst is plain text, it is easy to view and edit on any platform. For “nice” rendering (not just raw markup), you typically run a renderer/converter (Docutils) or build the documentation with Sphinx, rather than relying on the operating system to preview it.

Common MIME types: text/prs.fallenstein.rst

Further reading

Authoritative resources for more details on the .RST format.

Common .RST issues

The file opens as plain text and looks “unformatted”

reStructuredText is a markup language stored as plain text, so a normal editor will show the raw markup rather than a styled document.

  1. Open it in a text editor for reading/editing the source.
  2. If you want a styled view, render/convert it using Docutils or build it using Sphinx to produce HTML (or another output format).

Double-clicking does not open the file or opens in the wrong app

Your system may not have a file association for .rst (or it is associated with an app you do not want).

  1. Use “Open with” and choose a text editor to view it.
  2. Optionally change the default app association for .rst to your preferred editor.

Rendering/build fails due to syntax or directive errors

Docutils/Sphinx can reject or warn about invalid reStructuredText syntax, indentation problems, or unsupported directives/roles.

  1. Validate the document against the reStructuredText specification and fix indentation/structure issues.
  2. If building with Sphinx, confirm the directives/roles used are supported by your Sphinx configuration and extensions.

Text displays with strange characters or wrong line breaks

The file may use an unexpected encoding or line-ending style.

  1. Reopen the file and try a different text encoding (commonly UTF-8) in your editor.
  2. If needed, convert line endings (CRLF/LF) using your editor settings or a text conversion tool.

FAQ

Is .rst the same as Markdown?

No. Both are lightweight markup languages, but .rst usually means reStructuredText, with different syntax and tooling (commonly Docutils and Sphinx).

What MIME type should .rst use?

Commonly used is text/x-rst (as in the freedesktop.org shared MIME database). There is also an IANA-registered type: text/prs.fallenstein.rst.

Can I convert .rst to HTML or other formats?

Yes. reStructuredText is designed to be processed by tools such as Docutils, and Sphinx can build documentation from .rst into HTML and other outputs.

Can I fix a broken .rst by renaming the extension?

No. Renaming only changes the filename suffix. If it is not actually reStructuredText (or is corrupted), you will need the correct source or a proper conversion/export from the originating workflow.

Similar file extensions

Compare related formats in the same category to find the right tool faster.

Did this guide help?