Export as simple HTML (without any styles)

I want to export md text to simple html to paste in my WordPress blog. I tried 2 plugins: copy to html and Obsidian Enhancing Export

The problem is that the copy of first plugins is full of ID’s and DIV’s while the second plugins exports the html with a bunch of CSS and other stuff.

I need simple html only! At the moment I always copy the md text to “iA Writer” which handles this perferctly. But I would like to handle this workflow in obsidian only.

Anybody knows how to do that?
Thank you! :slightly_smiling_face:

Try the Copy document as HTML plugin. In its options enable “Copy HTML fragment only”. Then open the Command Palette and type “copy html entire” and select the first result. The HTML is copied and what you paste will be without CSS, only the content from inside <body>.

This will still have some <div>s which I now realise you did state that you didn’t want. If I understand you correctly, your goal is to end up with mostly plain text, but keep things like emboldened words and tables. Another plugin may offer this I’m not sure. You may have to stick to using iA Writer or some other third-party tool which can selectively strip HTML elements.

Thanks a lot for your comment @PKMian.
The plugin you mentioned adds a data attribute to each heading and some other stuff when it is copied. This is ultimately not harmful, but it is annoying. I’d prefer to have clean html.
Thank you anyway.

Try a normal select and copy in reading view.

Did you try this? Of course I did. It was my first idea. You get plain text then – no html formatting.

I’ve done it before and gotten formatted text. Probably the field you’re pasting into only accepts plain text.

Hmmm – anyway, I don’t need formatted text. I need html text. :wink:

<h1>My Headline</h1>
<p>my text goes here.</p>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.