Format code snippets for developer documentation
Prepare readable source code for tutorials, API guides, release notes, knowledge bases, and internal engineering documentation.
How to format a code snippet for documentation
- Paste the example and choose its language.
- Keep indentation and add line numbers when they help readers.
- Copy the result into your documentation or export an image.
Choose text or an image
Copy text when readers may reuse the code. Export an image when the destination does not preserve rich formatting.
Start highlighting code · Code to Word · Supported languages