mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-07 03:18:23 -05:00
[GH-ISSUE #16511] feat: Export chat as markdown / zip with optional Obsidian compatibility #56601
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Lucy-dot-dot on GitHub (Aug 12, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/16511
Check Existing Issues
Problem Description
I often find myself trying to save my chats to Obsidian / Markdown for archival purposes. Right now I copy each message and paste them into Obsidian, excluding images right now
Desired Solution you'd like
The ability to export a chat as Markdown, if images are contained, those may result in a zip or inline rendered. Inline render may result in external editors lagging.
Alternatives Considered
Writing my own rust based solution to transform the json export into the obsidian format
Additional Context
No response
@rgaricano commented on GitHub (Aug 12, 2025):
are you tried some json-markdown obsidian plugin?
(e.g. https://github.com/farling42/obsidian-import-json or https://github.com/ethanolivertroy/obsidian-markitdown)
@Lucy-dot-dot commented on GitHub (Aug 12, 2025):
It seems like the obsidian-import-json plugin requires manual configuration for each user. It does seem to do what I need. Obsidian-markitdown seems like a bad choice since PDFs are notoriously hard to transform into any other good format and keep the style. Having an easy to use export option may be the easiest for compatibility and usage.
I can try to implement this myself however I'm sure a more skilled developer may create a better experience with that
@rgaricano commented on GitHub (Aug 12, 2025):
Obsidian-markitdown also can import json files.
(I didn't try, I didn't use obsidian since months, will try later)
@Lucy-dot-dot commented on GitHub (Aug 12, 2025):
Thanks for trying, I have written a CLI tool for myself that does what I need but that isn't a general user friendly solution
@rgaricano commented on GitHub (Aug 12, 2025):
Lucy,
From what source do you convert it? pdf, json or plain text?
can you share the conversion function that give you a good markdown rendering?
@Lucy-dot-dot commented on GitHub (Aug 12, 2025):
I use json as the source, I will upload the source code in a seperate repository, it's quick written so it's not pretty and I haven't gotten around to image
@Lucy-dot-dot commented on GitHub (Aug 12, 2025):
https://github.com/Lucy-dot-dot/json-to-md/blob/main/src/main.rs
There you go, if you need a precompiled binary or need me to provide an example, tell me about it
@Lucy-dot-dot commented on GitHub (Aug 12, 2025):
Looking at the json with images, it seems like it's only possible to get the image seperately and it needs authentication, which makes it harder for me, but not impossible to produce a working cli application
@rgaricano commented on GitHub (Aug 12, 2025):
yes, images should also be downloaded as local files.
An option is as zip, with related files inside assets folder, and Obsidian can import it with the own textbundle importer.
As it's done in own open-webui instance auth shouldn't be a problem.
@Lucy-dot-dot commented on GitHub (Aug 12, 2025):
Ah sorry for the confusion, the authentication only is an issue for my own cli application. I think the zip idea is great. Should I edit my initial feature request to include this as my preferred proposal?
@rgaricano commented on GitHub (Aug 12, 2025):
Lucy,
I found an easier way: export it as text and rename as .md
Text export is rendered as markdown
@Lucy-dot-dot commented on GitHub (Aug 12, 2025):
In this case, at least for me, images generated using the image generation feature are not included by the txt export (which is part of the files section in the json) and thus is not rendered in the txt file. Although I will absolutely use the txt export now for most of my stuff. Thanks for the heads up there
@rgaricano commented on GitHub (Aug 12, 2025):
Text of text exported chat with iframe embedded it's a little odd (but it's for iframe heights not setted, it's just a test in my end)
(I test md with typora, iframe content is operative)
@rgaricano commented on GitHub (Aug 12, 2025):
ok, then it's only necessary add the local generated images to text exporter and download its also, or embedd raw data of those images as base64 in same file ... I'm going to take a look for the easier way and do some test with images.