Obsidian Advanced Formatting
SOURCE - Advanced formatting syntax - Obsidian Help
Learn how to add advanced formatting syntax to your notes.
Tables¶
You can create table using vertical bars (|
) and hyphens (-
). Vertical bars separate columns, and hyphens define the column header.
First name | Last name |
---|---|
Max | Planck |
Marie | Curie |
The vertical bars on either side of the table are optional.
Cells don't need to be perfectly aligned with the columns. Each header row must have at least two hyphens.
Format Content within a Table¶
You can use Obsidian-Basic-Formattingto style content within a table.
| First column | Second column |
| ------------------ | --------------------------------------- |
| [Internal links](Internal links.md){#904f1ab985f80d256e815d05d862e53d}| Link to a file _within_ your **vault**. |
| [Embed files](Embed files.md){#ea41bc45c0cdc87ad0c82fa887615183}| ! [100](Engelbart.jpg\.md){#c1a561f84a792300a22ccb449cdd74a8}|
Vertical bars in tables
If you want to use aliases, or to resize an image in your table, you need to add a \
before the vertical bar.
> First column | Second column
> -- | --
> [Markdown syntax](Basic formatting syntax\.md){#f0b73f6d63d9b5325cd53872382a9408}| {width=200 loading=lazy}
You can align text to the left, right, or center of a column by adding colons (:
) to the header row.
Left-aligned text | Center-aligned text | Right-aligned text
:-- | :--: | --:
Content | Content | Content
Left-aligned text | Center-aligned text | Right-aligned text |
---|---|---|
Content | Content | Content |
Diagram¶
You can add diagrams and charts to your notes, using Mermaid. Mermaid supports a range of diagrams, such as flow charts, sequence diagrams, and timelines.
Tip
You can also try Mermaid's Live Editor to help you build diagrams before you include them in your notes.
To add a Mermaid diagram, create a mermaid
code block.
```mermaid
sequenceDiagram
Alice->>+John: Hello John, how are you?
Alice->>+John: John, can you hear me?
John-->>-Alice: Hi Alice, I can hear you!
John-->>-Alice: I feel great!
```
sequenceDiagram
Alice->>+John: Hello John, how are you?
Alice->>+John: John, can you hear me?
John-->>-Alice: Hi Alice, I can hear you!
John-->>-Alice: I feel great!
graph TD
Biology --> Chemistry
Linking Files in a Diagram¶
You can create internal links in your diagrams by attaching the internal-link
class to your nodes.
graph TD
Biology --> Chemistry
class Biology,Chemistry internal-link;
Note
Internal links from diagrams don't show up in the Graph view.
If you have many nodes in your diagrams, you can use the following snippet.
```mermaid
graph TD
A[Biology]
B[Chemistry]
A --> B
class A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z internal-link;
```
This way, each letter node becomes an internal link, with the node text as the link text.
Note
If you use special characters in your note names, you need to put the note name in double quotes.
Or, A["⨳ special character"]
.
For more information about creating diagrams, refer to the official Mermaid docs.
Math¶
You can add math expressions to your notes using MathJax and the LaTeX notation.
To add a MathJax expression to your note, surround it with double dollar signs ($$
).
You can also inline math expressions by wrapping it in $
symbols.
This is an inline math expression \(e^{2i\pi} = 1\).
For more information about the syntax, refer to MathJax basic tutorial and quick reference.
For a list of supported MathJax packages, refer to The TeX/LaTeX Extension List.
Backlinks:
Obsidian Basic Formatting
Learn how to apply basic formatting to your notes, using https://daringfireball.net/projects/markdown/. For more advanced formatting syntax, refer to Obsidian-Advanced-Formatting.