top | item 40982118

Import and Export Markdown in Google Docs

652 points| pentagrama | 1 year ago |workspaceupdates.googleblog.com

135 comments

order
[+] tomeraberbach|1 year ago|reply
Hey folks, I'm the engineer who implemented the new feature. Just clearing up some confusion.

A lot of you are noticing the preexisting automatic detection feature from 2022 [1], which I also worked on. That's NOT what this newly announced feature is. The new feature supports full import/export, but it's still rolling out so you're likely not seeing it yet!

Hope you like it once it reaches you :)

[1] https://workspaceupdates.googleblog.com/2022/03/compose-with...

[+] andybak|1 year ago|reply
The main effect of slow rollouts on me is that I never use the feature. It goes like this.

1. There's a service I use sporadically or used to use

2. They announce a new feature that might potentially mean I'll start using it again/more

3. I read the post, log in and realise I don't have access yet

4. I completely forget this ever happened.

Surely all the effort that goes into announcing these things is a bit wasted ?

What happened to the a nice "Labs" switch to opt into stuff that's new and a bit raw?

[+] remoquete|1 year ago|reply
Such a huge quality of life improvement for technical writers who rely on Gsuite collaboration features while editing Markdown docs. Thank you!
[+] munificent|1 year ago|reply
You are my hero.

I work at Google in open source so I am constantly converting Google Docs to Markdown to put them on GitHub and vice versa. This will save me a lot of effort.

[+] supriyo-biswas|1 year ago|reply
Is it possible to get this feature in Slides as well?

I often need to prepare technical slides with code in it, and being able to just backtick away into a <code> tag or a <pre> block would be a godsend.

[+] hellojebus|1 year ago|reply
Will the API support uploading conversion of markdown to "application/vnd.openxmlformats-officedocument.wordprocessingml.document"? I process thousands of documents each month -- often have to parse from HTML to Markdown to Docx then finally upload and convert to Google Doc format.
[+] ahimthedream|1 year ago|reply
Can I sync MD files to drive through the osx drive integration? Allowing me to work on a local file in MD, but others can view through web
[+] _boffin_|1 year ago|reply
Question: when coming up with tests (whatever level they might be) before you submit your code, what’s your thought process about what tests to include? What edge cases to handle? What to not test? Is there much disagreement about what to test?
[+] sandbx|1 year ago|reply
I would like to be able to open and edit .md files in Google Docs on desktop and mobile like how Google Docs supports opening .docx files
[+] jez|1 year ago|reply
How does it handle images in the imports and exports?
[+] zikani_03|1 year ago|reply
Is this also available from the googlecloud APIs libraries? Would be neat to be able to create a Google Doc from markdown content, it's something we were going to look into for one of the things we are building.
[+] westurner|1 year ago|reply
Thanks!

Google Colab also supports Markdown input cells as "Text" with a preview.

Does this work with Google Sites?

How to create a Google Sites page from a Markdown doc, with MyST Markdown YAML front matter

NotebookLM can generate Python, LaTeX, and Markdown.

How to Markdown and Git diff on a Chromebook without containers or Inspect Element because [...]

How to auto-grade Jupyter Notebooks with Markdown prose, with OtterGrader

How to build a jupyter-book from .rst, MyST Markdown .md, and .ipynb jupyter/nbformat notebooks containing MyST Markdown

[+] chrisfinazzo|1 year ago|reply
I would have expected this to export CommonMark, but it seems like it's not quite up to that yet. Is that on the board for a future release?

This isn't to say I prefer CM -- because Markdown came into being from Gruber's script. In a literal sense, "Markdown" is defined as whatever `markdown.pl` is, warts and all -- however, contact with the outside world forced things to move in a direction that is (so to speak) more organized that what John originally wrote.

[+] lewisjoe|1 year ago|reply
Hi, thanks for this amazing work.

Just curious: Google docs supports a lot more than what Markdown has syntaxes for - how do you deal with this when exporting to markdown?

[+] freedomben|1 year ago|reply
I just wanted to say, it took me a while to discover it (it happened by accident), but the preexisting feature from 2022 was a joy to discover! I didn't know you obviously, but I praised the kind anonymous soul out there who did that. I discovered it about 6 months ago, and I use it all the time now. I'm super excited to see it progress!
[+] hereme888|1 year ago|reply
Duuuuuuuuude, I was just thinking a few days ago: how come markdown isn't yet a thing in word editors?

Well, you solved it. Thanks!

[+] chrisbrandow|1 year ago|reply
Any idea how long is this rollout going to be? I still don't have access to it. (not that you're in charge of the rollout pace)
[+] davecahill|1 year ago|reply
The announcement of the new feature (which I don't have just yet) made me realize that the automatic detection feature existed, and I love it. :)
[+] ted_dunning|1 year ago|reply
I can't wait.

This will make a huge difference to a lot of my work.

[+] tomgp|1 year ago|reply
Thank you! This is going to make my life MUCH easier
[+] RandomWorker|1 year ago|reply
Thanks for doing this! It’s amazing feature to use docs to compose and paste to my Hugo blog. Very good workflow
[+] sbergot|1 year ago|reply
Thank you for making that! I was using a plugin to export to markdown but it wasn't ideal.
[+] shadowgovt|1 year ago|reply
Super cool. Well done! I've been wanting this for awhile; glad to see it.
[+] Freak_NL|1 year ago|reply
No support for code blocks still:

    ```java
    String x = "xxx";
    ```
No quoting:

    The docs for `libfloof` state:

    > The floof is 4 bytes long, at most.
And when I type `code` with backticks at the start of a line, the word 'code' is formatted as code as expected, but auto-correct automatically capitalises it to 'Code' — which should never be done with code fragments.

So this is basically just headings, italics, bold, and links?

It's really annoying when you need to share technical documentation with lots of code and code-like content with people and they've started doing the spec in Google Drive. Just give me working Markdown.

[+] CityOfThrowaway|1 year ago|reply
My guess is that this is strongly motivated by the success of LLMs.

The lack of MD support makes manual IO from Docs to your favorite LLM lossy (or very annoying). Cool that it's fixed.

[+] staticman2|1 year ago|reply
They also already have to support Gemini to Google Docs and vice versa so it makes sense they'd have to support Markdown in some fashion on the backend.
[+] thallavajhula|1 year ago|reply
At this point, most major changes could be motivated by LLMs/AI.
[+] Crier1002|1 year ago|reply
i hope they'll eventually support Mermaid (https://github.com/mermaid-js/mermaid) for creating diagrams directly within documents. i've been using it a lot for my markdown files and it works amazingly well with LLMs (e.g. asking LLM to generate the diagram representation of something using Mermaidjs)
[+] asah|1 year ago|reply
+1 mermaid please !!!!
[+] bomewish|1 year ago|reply
If this is implemented properly it’ll be a game changer for collaboration on papers. Means one can write a paper with colleagues in markdown and then easily knit with pandoc/quarto. Cheaper than overleaf etc.
[+] Symbiote|1 year ago|reply
You can already get most of the way there, as Pandoc supports reading the ODT or DOCX export from Google Docs reasonably well.

I have this in my shell history:

  pandoc --from=docx --to=asciidoc --wrap=none --atx-headers --extract-media=img doc.docx > doc.adoc
[+] gouggoug|1 year ago|reply
I'll add that writing a paper might be better handled by a more feature-full format like Asciidoc.
[+] protortyp|1 year ago|reply
I recently used Typst and their own collab solution for a paper we worked on. While some features are still lacking it was a pretty good experience overall.
[+] bt1a|1 year ago|reply
Why not a markdown doc + git with each colleague using their own text editor/IDE of choice?
[+] eskibars|1 year ago|reply
This would have been very useful at several companies I worked at as a product manager for release blogs.

I always start editing in gdocs because it's so much easier to collaborate on than any blog platform, but then you always need to copy/paste the content once final into the blog and nearly every time, it copies some elements of formatting into the rich HTML editor I don't want (fonts, font sizes, etc) while I do want some things (headings, bold, italics). It's usually easy to import markdown to blogs or trivial to convert it to stripped-down HTML that can be imported. One of the teams I worked on built a simple gdoc script to do this

[+] gempir|1 year ago|reply
Does this just import Markdowns and convert them to Gdoc and then you export it finally. Or can you collaborate on Markdowns in real time?

Could you build a confluence/wiki like system on top of this?

[+] freedomben|1 year ago|reply
Whoa, this is a huge, huge deal for me. This is going to make Google Docs incredibly more useful, and will provide some functionality that I've currently been working around using vim block editing and macros (hey now, vim mode is a great next project for google docs :-D). Ability to import/export as markdown will also be a game changer for less technical people who want to contribute to technical documentation. I strongly prefer technical docs to be in markdown and under version control, and that makes it hard for people. This doesn't solve the git learning curve of course, but that part is pretty manageable.

Thank you to the people who made this happen! May you continue your great work for a long time to come!

[+] yosito|1 year ago|reply
I don't really use Google products, so I find this particularly useful for collaborating with people who do. I can do my shit in Markdown, they can do their shit in Google, and we can easily transfer the content back and forth.
[+] xnx|1 year ago|reply
So close. I have always hoped for an edit in markdown (or limited formatting) mode.
[+] red_admiral|1 year ago|reply
This is a cool feature, even if parts of markdown still need to be implemented (for pedants: commonmark).

Meanwhile, Trello is once again threatening to force everyone onto the new rich-text editor and disable the old markdown one.

[+] worldmerge|1 year ago|reply
This is really useful! Hope they continue to add features. I don’t like directly writing markdown and would rather use a text editor like Docs or Word.
[+] d4rkp4ttern|1 year ago|reply
I like to have AI auto-complete assistance from something like GitHub copilot, so I often compose markdown within PyCharm and then paste to Google docs. There seem to be zillions of “AI-writing” tools out there but I’m shocked that nothing has replaced the smooth functionality of GitHub copilot. Google docs with Gemini is not smooth at all. Tried obsidian plugins but they are janky.
[+] mikelnrd|1 year ago|reply
Is there an API to export a Google doc as markdown?
[+] orliesaurus|1 year ago|reply
I guess most users of Google Docs have no use for this, especially the download as markdown. I wonder why they decided to add this feature for the tech crowd so late in the lifecycle of the product, feels almost like an Summer '24 intern project?
[+] mavsman|1 year ago|reply
I would imagine that requests for this feature went way up as ChatGPT has popularized.
[+] jfoster|1 year ago|reply
Interesting announcement. Feels like some of it is just copy-pasted from a PRD. Not necessarily a bad thing (it's clearer than press release style), just the first time I've noticed it in a "bigtech" announcement.