How to open .RST files on Linux

To open .RST files on Linux, open the .rst file in any text editor to view or edit the markup.

Step-by-step instructions

  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.

Common 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.

Security note

.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.

Back to .RST extension page