Hide tags in preview mode

Hi all,

is there any way to hide tags in preview mode?

Regards Stefan

You mean #hashtags, yes? There should be, as Obsidian provides a class for tags. See e.g., Meta Post - Common CSS Hacks.

You’ll want to target the .tag class inside .markdown-preview-view and set it to display: none;, I imagine.

Thank you. As I am new to CSS Hacks regarding Obsidian, where can I found the class you mentioned? I did not find it in the Obsidian.css … or where is the default css file?

Thanks again, Stefan

Appending the following to any Obsidian .css seems to do it:

.markdown-preview-view .tag {
    display: none;

Thank you very much @ryanjamurphy. This works fine. Is there any documentation regarding the CSS settings. As I looked through the mentioned Meta Post there is much potential for customization.
Regarding my question this thread could be archived. Thanks again!

There could be more, but it’s a tough thing to document. Creating a more fulsome “teach a person to CSS (in Obsidian)” guide is on the mods’ todo list (as it would be better than this piecemeal “feed a person CSS”-type help)!

1 Like