How to modify color and background of an alias

I’ve not yet found a way to modify the look of an alias in my roam/css.

For instance, when I use {{alias:[[Nassim Nicholas Taleb]] Nassim Taleb}} to associate Nassim Taleb in a block to the Nassim Nicholas Taleb, Roam show the aliased name as red text on light grey background.

Thanks in advance for your help or redirecting me where this question was answered (I searched on this forum and internet without success).


This is for a block alias:

.rm-block-text span[style*=“cursor: alias;”] {
color: #0ab4ff !important;
background-color: #2b343b !important;
.rm-block-text span[style*=“cursor: alias;”]:hover {
background-color: #2188d8 !important;
color: #ffffffc4 !important;

This is for a page alias:

a.rm-alias.rm-alias-page {
color: #f90 !important;
font-weight: bolder;
a.rm-alias.rm-alias-page:hover {
color: rgba(8, 199, 224, .85) !important;
font-weight: bolder;

Hope that helps!

1 Like

Hi @jonjimenez33

Thanks for taking the time to answer my question. I just loaded your script, but it did not change the color scheme of the alias

Actually, I completely scrap my roam/css and only put you script and I can’t see what it’s changing. Switched Browser in case, and still no impact.

I don’t know.

1 Like

What browser are you using? And did you make sure you have the “CSS” language selected in your code block?

Actually, I think I figured this out. For some weird reason you have to delete and reënter the quotations around ---- “cursor: alias;” -----

When you copy and paste my code it changes the format which makes it not work.

cap 1
cap 2

Note that the code is the exact same but the color of the style is different

1 Like

Superb! It works. Thanks a lot for your help and time @jonjimenez33

Have you tried using a link as an Alias? For example:


Where “…” can be a block, page or hyperlink?

So, for example:

Page Alias:

  • [Nassim Taleb]([[Nassim Nicholas Taleb]])

Block Alias:

  • [Nassim Taleb](((xkje38ks)))

Hyperlink Alias:

  • [Nassim Taleb](

These would all be considered Aliases, but have different functions.


Hi Chris,

Indeed, the Page Alias is a simple idea I did not think of. I like it. Many thanks.


I was using {{alias:[[Page Name]]replacement text}} and was getting some crappy inline styling I couldn’t override, so I came here to see if there was a better way… There definitely is!

Thanks :grin:

What’s this {{alias:…}} syntax for then? Do you know?

Thanks again!

1 Like

Amazing, thank you for sharing this