Skip to main content
Plugins allow you to package and distribute custom converters as standalone Python packages. MarkItDown automatically discovers and loads plugins using Python’s entry points system.

Plugin Architecture

MarkItDown uses the markitdown.plugin entry point group to discover plugins. When enable_plugins=True, MarkItDown calls each plugin’s register_converters() function during initialization.
Plugins are disabled by default. Users must explicitly enable them with enable_plugins=True or the --use-plugins CLI flag.

Creating a Plugin

Complete Example: RTF Plugin

Here’s the complete RTF converter plugin from packages/markitdown-sample-plugin/:

Installing and Testing Your Plugin

Writing Plugin Tests

Create tests to verify both direct converter usage and plugin loading:

Plugin Loading Process

MarkItDown loads plugins using this process (_markitdown.py:65):
  1. When enable_plugins=True, MarkItDown calls enable_plugins() method
  2. _load_plugins() discovers all markitdown.plugin entry points
  3. Each entry point is loaded and its register_converters() function is called
  4. If any plugin fails to load, a warning is issued and the plugin is skipped

Best Practices

Version Compatibility: Always set __plugin_interface_version__ = 1 and specify minimum MarkItDown version in dependencies.
Graceful Degradation: Handle import errors for optional dependencies and provide helpful error messages.
Priority Configuration: Allow users to pass priority via **kwargs in register_converters():
Documentation: Include clear README with installation instructions and example usage.

Publishing Your Plugin

To share your plugin with others:
  1. Naming Convention: Use markitdown-<name>-plugin for package name
  2. PyPI Publishing: Follow standard Python package publishing process
  3. Documentation: Include clear installation and usage instructions
  4. Testing: Ensure comprehensive test coverage
Users can then install your plugin:

Next Steps

Custom Converters

Learn more about implementing converters

Configuration

Understand MarkItDown configuration options