Convert files to various formats

View as MarkdownMarkdown

Set up your AI agent

Give your coding agent live access to the GroupDocs documentation and API reference through the GroupDocs Docs MCP server — no install, no API key. Learn more

claude mcp add --transport http groupdocs-docs https://docs.groupdocs.com/mcp

Also process documents locally

The GroupDocs.Markdown MCP server lets your agent work with files on your machine; they are never uploaded. It needs the .NET 10 SDK or Docker.

claude mcp add groupdocs-markdown -- dnx GroupDocs.Markdown.Mcp --yes
Folders, licensing and more →

GroupDocs.Markdown provides a quick and easy way to convert documents into clean, structured Markdown. The library offers two approaches: static methods for one-line conversions and an instance API for more control.

Static methods (simplest)

Call MarkdownConverter.ToMarkdown() to get a Markdown string, or MarkdownConverter.ToFile() to write directly to disk:

using GroupDocs.Markdown;

string md = MarkdownConverter.ToMarkdown("business-plan.docx");
// # Quarterly Report
//
// ## Executive Summary
//
// This report covers the key initiatives...

MarkdownConverter.ToFile("business-plan.docx", "static-methods.md");

Instance API

Create a MarkdownConverter instance for advanced scenarios such as inspecting metadata before converting or reusing a loaded document:

using GroupDocs.Markdown;

using var converter = new MarkdownConverter("business-plan.docx");
converter.Convert("instance-api.md", new ConvertOptions { HeadingLevelOffset = 1 });

Conversion options

Use ConvertOptions to customize the output – select specific pages, control image handling, choose a Markdown flavor, add YAML front matter, and more. For loading customization, use LoadOptions to specify file format or provide a password.

These documentation articles explain how to convert files from the most popular formats: