md2linkedin 
md2linkedin converts Markdown text to LinkedIn-compatible plain text by
replacing bold, italic, and bold-italic markers with Unicode Mathematical
Sans-Serif characters. This preserves visual formatting when pasting into
platforms like LinkedIn that do not support Markdown natively.
Use it in your browser
Just want to write a post? The
LinkedIn post formatter
runs md2linkedin in your browser, with nothing to install. Format your post
with a toolbar (bold, italics, headings, lists, and code), watch the LinkedIn
version update as you type, and copy it with one click. Your text never leaves
your device.
Install the package when you want to convert Markdown files, script the conversion, or call it from Python.
Installation
uv add md2linkedin
Tip: Run the CLI without installing it through
uvx:uvx md2linkedin post.md. Every CLI example below works the same way.
Usage
Python API
# @pyodide
from md2linkedin import convert
md = """
# Exciting News
I'm thrilled to share that **we just launched** a new product!
Key highlights:
- **Performance**: *3x faster* than the previous version
- **Reliability**: ***zero downtime*** deployments
- **Developer UX**: clean, intuitive API
Check it out and let me know what you think.
"""
print(convert(md))
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
𝗘𝗫𝗖𝗜𝗧𝗜𝗡𝗚 𝗡𝗘𝗪𝗦
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
I'm thrilled to share that 𝘄𝗲 𝗷𝘂𝘀𝘁 𝗹𝗮𝘂𝗻𝗰𝗵𝗲𝗱 a new product!
Key highlights:
• 𝗣𝗲𝗿𝗳𝗼𝗿𝗺𝗮𝗻𝗰𝗲: 3𝘹 𝘧𝘢𝘴𝘵𝘦𝘳 than the previous version
• 𝗥𝗲𝗹𝗶𝗮𝗯𝗶𝗹𝗶𝘁𝘆: 𝙯𝙚𝙧𝙤 𝙙𝙤𝙬𝙣𝙩𝙞𝙢𝙚 deployments
• 𝗗𝗲𝘃𝗲𝗹𝗼𝗽𝗲𝗿 𝗨𝗫: clean, intuitive API
Check it out and let me know what you think.
CLI
# Convert a Markdown file (output: post.linkedin.txt)
md2linkedin post.md
# Specify output path
md2linkedin post.md -o linkedin_post.txt
# Pipe from stdin
echo "**Hello**, *world*!" | md2linkedin
# Keep link URLs in the output
md2linkedin post.md --preserve-links
# Disable monospace code rendering
md2linkedin post.md --no-monospace-code
Key Features
- Bold:
**text**or__text__→ Unicode Sans-Serif Bold (𝗯𝗼𝗹𝗱) - Italic:
*text*or_text_→ Unicode Sans-Serif Italic (𝘪𝘵𝘢𝘭𝘪𝘤) - Bold-italic:
***text***or___text___→ Unicode Sans-Serif Bold Italic (𝙗𝙤𝙡𝙙-𝙞𝙩𝙖𝙡𝙞𝙘) - Headers:
#/##/etc. styled with bold Unicode; H1 is also uppercased between━borders - Code spans and blocks: backticks, fences and indent stripped; content rendered in Unicode Monospace (𝚌𝚘𝚍𝚎) by default, or kept plain with
--no-monospace-code - Links: stripped to display text by default;
--preserve-linksretains URLs - Images: replaced by alt text
- Bullet lists:
-/*/+→•; nested items get one marker per level (‣,◦,▪) - Ordered lists: numbered in sequence from the list's first number (
1.,1.→1.,2.) - Tables: header row in bold, cells joined by
| - Strikethrough and highlight:
~~text~~and==text==→text, markers dropped - Blockquotes: leading
>stripped at every level of nesting - HTML spans: unwrapped, inner text preserved
- HTML entities: decoded (
&→&, etc.) - Backslash escapes: resolved (
\*→*) - Windows line endings: normalised automatically
- Accented letters: styled like the letters around them (
**Grüße**→ 𝗚𝗿𝘂̈ß𝗲);ß,łand other letters with no ASCII base stay plain - Greek: bold and bold-italic in sans-serif (
**Ωμέγα**→ 𝝮𝝻𝝴́𝝲𝝰), italic in serif, the closest Unicode has; code stays plain - Emojis & other scripts: pass through unchanged — no accidental corruption
Limitations
Styling relies on Unicode Mathematical Alphanumeric Symbols, which has trade-offs:
- Other scripts: Unicode has styled letters only for Latin, Greek, and digits, so text in every other script (Cyrillic, Arabic, Hebrew, Devanagari and other Indic scripts, Thai, Chinese, Japanese, Korean, …) stays plain inside bold, italic, headings, and code. md2linkedin cannot fix this: the characters it would need do not exist, and LinkedIn posts have no other way to carry formatting.
find_unstyled()lists the affected words so you can warn about them. See Scripts without styled letters. - Code blocks: LinkedIn's proportional font does not keep monospace Unicode characters fixed-width, so indentation and column alignment often break.
- Tables: for the same reason, flattened table columns do not line up; rewrite wide tables as lists.
- Accessibility: screen readers often spell out each styled character (e.g. "mathematical sans-serif bold b") instead of reading whole words.
- Searchability: LinkedIn search may not index styled text, so people searching for those keywords might not find your post.
- Markdown extensions: only CommonMark plus tables, strikethrough, autolinks and
==highlight==are read. Task-list checkboxes stay as literal[ ]/[x]and footnotes are flattened (text[^1]→text^1); see What Gets Transformed.
See Also
- Documentation — advanced usage, the full conversion table, and the API reference.
License
This project is licensed under the MIT License.
Code of Conduct
Please note that the md2linkedin project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.
Acknowledgements
Hex sticker font is Rubik. Icons are sourced from
Flaticon:
Metadata
Release files for md2linkedin 0.7.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| md2linkedin-0.7.0.tar.gz | 18.7 kB | With provenance | Details for md2linkedin-0.7.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| md2linkedin-0.7.0-py3-none-any.whl | Python 3 | none | any | Details for md2linkedin-0.7.0-py3-none-any.whl |
Total release size: 37.0 kB
Release files / md2linkedin-0.7.0.tar.gz
| Download URL | md2linkedin-0.7.0.tar.gz |
|---|---|
| Size | 18.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
094f1bbb711d4a1b5ed2542b4dcc7021b9a5d3ea47d65187b51908fcef037a42
|
|
BLAKE2b-256 checksum How to use checksums |
cacb3c47bd4cd1d12e069cac847a3eb41ae54933b201962b9cca8ae4c037535b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 30, 2026.
Transparency logRelease files / md2linkedin-0.7.0-py3-none-any.whl
| Download URL | md2linkedin-0.7.0-py3-none-any.whl |
|---|---|
| Size | 18.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
16f13c98fedeadcbd8a4850b38884088a7de04e1413abb6e6e319204eac16769
|
|
BLAKE2b-256 checksum How to use checksums |
48f4e8249e2b9b3ffc4241a0fc88c6aa4bf0111cc749e2c393991cf5692cb7d2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 30, 2026.
Transparency logSecurity for md2linkedin 0.7.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for md2linkedin-0.7.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 30, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.