Skip to content

Instantly share code, notes, and snippets.

@thomasbnt
Last active November 21, 2024 22:38
Show Gist options
  • Save thomasbnt/b6f455e2c7d743b796917fa3c205f812 to your computer and use it in GitHub Desktop.
Save thomasbnt/b6f455e2c7d743b796917fa3c205f812 to your computer and use it in GitHub Desktop.
Code colors for embed discord.js

Here is an updated list of the colors that are currently implemented with a name. To using colors on discord.js, this is a typedef Colors, Colors.Aqua to get the Aqua color.

Name Int value Hex Code
Default 0 #000000
Aqua 1752220 #1ABC9C
DarkAqua 1146986 #11806A
Green 5763719 #57F287
DarkGreen 2067276 #1F8B4C
Blue 3447003 #3498DB
DarkBlue 2123412 #206694
Purple 10181046 #9B59B6
DarkPurple 7419530 #71368A
LuminousVividPink 15277667 #E91E63
DarkVividPink 11342935 #AD1457
Gold 15844367 #F1C40F
DarkGold 12745742 #C27C0E
Orange 15105570 #E67E22
DarkOrange 11027200 #A84300
Red 15548997 #ED4245
DarkRed 10038562 #992D22
Grey 9807270 #95A5A6
DarkGrey 9936031 #979C9F
DarkerGrey 8359053 #7F8C8D
LightGrey 12370112 #BCC0C0
Navy 3426654 #34495E
DarkNavy 2899536 #2C3E50
Yellow 16776960 #FFFF00

Official Discord color palette

Name Int value Hex Code
White (Default) 16777215 #FFFFFF
Greyple 10070709 #99AAb5
Black 2303786 #23272A
DarkButNotBlack 2895667 #2C2F33
NotQuiteBlack 2303786 #23272A
Blurple 5793266 #5865F2
Green 5763719 #57F287
Yellow 16705372 #FEE75C
Fuchsia 15418782 #EB459E
Red 15548997 #ED4245

Other role colors

Name Int value Hex Code
Unnamed role color 1 6323595 #607D8B
Unnamed role color 2 5533306 #546E7A
Background black color 3553599 #36393F

Unnamed colors


✨ Don't hesitate to follow me on GitHub, also sponsoring me on GitHub.

Sponsors are people who support the development of this project. If you want to support me, you can do it by clicking on the button below.

GitHub Sponsors

Sponsors

@aziznatour
Copy link

Hello thx but what is the code color @aziznatour ?

#FD0061 and the dark one is #BC0057

@thomasbnt
Copy link
Author

Is updated! thx again @aziznatour !

@Rex8217
Copy link

Rex8217 commented Dec 28, 2019

Heres a website that can convert them! You go to the Decimal Numbers and then copy. https://convertingcolors.com/

@thomasbnt
Copy link
Author

Yeep thx @Rex8217

@norioffical
Copy link

tysm

@AquaBucket
Copy link

nice color codes

@Militia21
Copy link

How do you put the colours though? Do you do 00fx before the tag?

@thomasbnt
Copy link
Author

What this @Militia21 for a example of using colors in embeds

https://leovoel.github.io/embed-visualizer/

@BSweet16
Copy link

BSweet16 commented Sep 17, 2020

@Militia21 You could just a system with enumerators such as this, where card colors are in an enumerated list. The function listed afterwards could then just be given a title, message body, and card color from the enumerator.
(Such as:
displayMessage('Success', 'Congratulations, this worked correctly.', cardColors.green);
displayMessage('Warning', 'This is not the worst thing in the world.', cardColors.yellow);
displayMessage('Error', 'Something went wrong... You should be ashamed...', cardColors.red);)

Enumerator:
enum cardColors{ red = '#FD0061', green = '#008E44', yellow = '#F8C300' }

Example Template:
function displayMessage (title: string = '', content: string = '', cardColor: string = cardColors.green){ let newMessage = { "embed": { "color": cardColor, "fields": [ { "name": ${title}, "value": ${content}, "inline": false } ] } }; message.channel.send(newMessage); }

@yasserprogamer
Copy link

nice you help me so much

@insomnia-creator
Copy link

Life savior here mate

@imacodr
Copy link

imacodr commented Nov 7, 2020

Thanks! Really helped.

@Leslato
Copy link

Leslato commented Nov 12, 2020

Thanks!

@MrlolDev
Copy link

https://htmlcolorcodes.com all the colors here

@Blessedwasnotfat
Copy link

Blessedwasnotfat commented Dec 1, 2020

there's also 'RANDOM' which does exactly what you think it does.... i actually had to do this the somewhat more difficult way which was doing Math.floor(Math.random() * 16777214) + 1

@thomasbnt
Copy link
Author

Of course, any color can be used. Thanks @Blessedwasnotfat for your message 🕺☕

@Starkiller4011
Copy link

Starkiller4011 commented Jan 14, 2021

Has anyone managed to get a proper white? I tried using #FFFFFF as well as rgb(255, 255, 255) and what I end up getting on my embeds is a weird grey. If I use #FFFFFD, rgb(255, 255, 253), I get an off-white but for some reason #FFFFFF gives grey lol

@decabitrunner
Copy link

It is so helpful thanks

@real2two
Copy link

real2two commented Mar 1, 2021

Has anyone managed to get a proper white? I tried using #FFFFFF as well as rgb(255, 255, 255) and what I end up getting on my embeds is a weird grey. If I use #FFFFFD, rgb(255, 255, 253), I get an off-white but for some reason #FFFFFF gives grey lol

same thing happening to me now

EDIT: 16777214 seems to work.

@Olympic1
Copy link

Olympic1 commented Mar 7, 2021

Here is an updated list of the colors that are currently implemented with a name

Name Int value Hex Code
DEFAULT 0 #000000
AQUA 1752220 #1ABC9C
DARK_AQUA 1146986 #11806A
GREEN 3066993 #2ECC71
DARK_GREEN 2067276 #1F8B4C
BLUE 3447003 #3498DB
DARK_BLUE 2123412 #206694
PURPLE 10181046 #9B59B6
DARK_PURPLE 7419530 #71368A
LUMINOUS_VIVID_PINK 15277667 #E91E63
DARK_VIVID_PINK 11342935 #AD1457
GOLD 15844367 #F1C40F
DARK_GOLD 12745742 #C27C0E
ORANGE 15105570 #E67E22
DARK_ORANGE 11027200 #A84300
RED 15158332 #E74C3C
DARK_RED 10038562 #992D22
GREY 9807270 #95A5A6
DARK_GREY 9936031 #979C9F
DARKER_GREY 8359053 #7F8C8D
LIGHT_GREY 12370112 #BCC0C0
NAVY 3426654 #34495E
DARK_NAVY 2899536 #2C3E50
YELLOW 16776960 #FFFF00

Official Discord color palette

Name Int value Hex Code
WHITE 16777215 #FFFFFF
BLURPLE 7506394 #7289DA
GREYPLE (Default) 10070709 #99AAB5
DARK_BUT_NOT_BLACK 2895667 #2C2F33
NOT_QUITE_BLACK 2303786 #23272A

Other role colors

Name Int value Hex Code
Unnamed role color 1 6323595 #607D8B
Unnamed role color 2 5533306 #546E7A

Unnamed colors

@thomasbnt
Copy link
Author

Thanks @Olympic1, I updated the file !

@SynergyBest
Copy link

life saver, thank you so much!

@Tomtom-Skywalker
Copy link

If This Is Still Being Maintained The Embed Its Self's Colour (The Part Where The Txt Goes) is #2F3136 the RGB 47,49,54 Name Is Unknown

@typedwaves
Copy link

Embed Color: #2F3136 (Useful if you want embeds without the color)

@thomasbnt
Copy link
Author

Embed Color: #2F3136 (Useful if you want embeds without the color)

@Starnamics yeep pretty nice embed !

@nlssn
Copy link

nlssn commented Jun 7, 2021

Here are the colors from the new branding guidelines announced on May 14th 2021.
The new color called "Blurple" has replaced #7289DA (which is now referred to as "OG Blurple").

Name                             | Int value | Hex code
---------------------------------|-----------|----------
`BLURPLE`                        | 5793266   | `#5865F2`
`GREEN`                          | 5763719   | `#57F287`
`YELLOW`                         | 16705372  | `#FEE75C`
`FUSCHIA`                        | 15418782  | `#EB459E`
`RED`                            | 15548997  | `#ED4245`
`WHITE`                          | 16777215  | `#FFFFFF`
`BLACK`                          | 2303786   | `#23272A`

@Resoki
Copy link

Resoki commented Oct 13, 2021

You can use 'RANDOM' too ;)

@thomasbnt
Copy link
Author

thomasbnt commented Oct 13, 2021

You can use 'RANDOM' too ;)

Yep of course!

Updated file, thanks ;)

Copy link

ghost commented Jan 22, 2022

tysm

@phil-flip
Copy link

phil-flip commented Sep 1, 2022

Hey. I thought I just let you know that colors in Discord.JS v14 have changed to lowercase.
So ex. "GREEN" becomes "Green" or "ORANGE" is now "Orange".

After testing around, unfortunately all colors need to be changed as sometimes it doesn't work, or it will use a different color... Which is kinda strange to happen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment