140 Color Names and hex value Supported by All Browsers:

Name CSS Value Live Demo
AliceBlue #F0F8FF
AntiqueWhite #FAEBD7
Aqua #00FFFF
Aquamarine #7FFFD4
Azure #F0FFFF
Beige #F5F5DC
Bisque #FFE4C4
Black #000000
BlanchedAlmond #FFEBCD
Blue #0000FF
BlueViolet #8A2BE2
Brown #A52A2A
BurlyWood #DEB887
CadetBlue #5F9EA0
Chartreuse #7FFF00
Chocolate #D2691E
Coral #FF7F50
CornflowerBlue #6495ED
Cornsilk #FFF8DC
Crimson #DC143C
Cyan #00FFFF
DarkBlue #00008B
DarkCyan #008B8B
DarkGoldenRod #B8860B
DarkGray #A9A9A9
DarkGrey #A9A9A9
DarkGreen #006400
DarkKhaki #BDB76B
DarkMagenta #8B008B
DarkOliveGreen #556B2F
DarkOrange #FF8C00
DarkOrchid #9932CC
DarkRed #8B0000
DarkSalmon #E9967A
DarkSeaGreen #8FBC8F
DarkSlateBlue #483D8B
DarkSlateGray #2F4F4F
DarkSlateGrey #2F4F4F
DarkTurquoise #00CED1
DarkViolet #9400D3
DeepPink #FF1493
DeepSkyBlue #00BFFF
DimGray #696969
DimGrey #696969
DodgerBlue #1E90FF
FireBrick #B22222
FloralWhite #FFFAF0
ForestGreen #228B22
Fuchsia #FF00FF
Gainsboro #DCDCDC
GhostWhite #F8F8FF
Gold #FFD700
GoldenRod #DAA520
Gray #808080
Grey #808080
Green #008000
GreenYellow #ADFF2F
HoneyDew #F0FFF0
HotPink #FF69B4
IndianRed #CD5C5C
Indigo #4B0082
Ivory #FFFFF0
Khaki #F0E68C
Lavender #E6E6FA
LavenderBlush #FFF0F5
LawnGreen #7CFC00
LemonChiffon #FFFACD
LightBlue #ADD8E6
LightCoral #F08080
LightCyan #E0FFFF
LightGoldenRodYellow #FAFAD2
LightGray #D3D3D3
LightGrey #D3D3D3
LightGreen #90EE90
LightPink #FFB6C1
LightSalmon #FFA07A
LightSeaGreen #20B2AA
LightSkyBlue #87CEFA
LightSlateGray #778899
LightSlateGrey #778899
LightSteelBlue #B0C4DE
LightYellow #FFFFE0
Lime #00FF00
LimeGreen #32CD32
Linen #FAF0E6
Magenta #FF00FF
Maroon #800000
MediumAquaMarine #66CDAA
MediumBlue #0000CD
MediumOrchid #BA55D3
MediumPurple #9370DB
MediumSeaGreen #3CB371
MediumSlateBlue #7B68EE
MediumSpringGreen #00FA9A
MediumTurquoise #48D1CC
MediumVioletRed #C71585
MidnightBlue #191970
MintCream #F5FFFA
MistyRose #FFE4E1
Moccasin #FFE4B5
NavajoWhite #FFDEAD
Navy #000080
OldLace #FDF5E6
Olive #808000
OliveDrab #6B8E23
Orange #FFA500
OrangeRed #FF4500
Orchid #DA70D6
PaleGoldenRod #EEE8AA
PaleGreen #98FB98
PaleTurquoise #AFEEEE
PaleVioletRed #DB7093
PapayaWhip #FFEFD5
PeachPuff #FFDAB9
Peru #CD853F
Pink #FFC0CB
Plum #DDA0DD
PowderBlue #B0E0E6
Purple #800080
RebeccaPurple #663399
Red #FF0000
RosyBrown #BC8F8F
RoyalBlue #4169E1
SaddleBrown #8B4513
Salmon #FA8072
SandyBrown #F4A460
SeaGreen #2E8B57
SeaShell #FFF5EE
Sienna #A0522D
Silver #C0C0C0
SkyBlue #87CEEB
SlateBlue #6A5ACD
SlateGray #708090
SlateGrey #708090
Snow #FFFAFA
SpringGreen #00FF7F
SteelBlue #4682B4
Tan #D2B48C
Teal #008080
Thistle #D8BFD8
Tomato #FF6347
Turquoise #40E0D0
Violet #EE82EE
Wheat #F5DEB3
White #FFFFFF
WhiteSmoke #F5F5F5
Yellow #FFFF00
YellowGreen #9ACD32

Understanding Color Formats in CSS

Basic Color Keywords 

The easiest way to start experimenting with colors in CSS is by using basic keywords. These are common color names like “red,” “blue,” “green,” “yellow,” and many more. There are over 140 recognized color keywords, offering a decent starting point for simple color choices.

Example

				
					HTML
<p style="color: orange;">This paragraph will have orange text.</p>
<div style="background-color: purple;">This div will have a purple background. </div>

				
			

Extended Color Keywords 

Want a more nuanced color palette? CSS expands its vocabulary with extended color keywords. These offer more specific shades like “teal,” “coral,” “lavender,” and “azure.” Imagine these as the more ‘sophisticated’ cousins of the basic color keywords.

Example

				
					HTML
<h1 style="color: aquamarine;">This heading will have an aquamarine color.</h1>
<button style="background-color: fuchsia;">This button will have a fuchsia background.</button>  

				
			

Tip: A full list of extended color keywords can be found on numerous resources. These often provide a surprisingly wide range of choices for most design needs.

Hexadecimal Color Codes

Hexadecimal color codes open up a vast spectrum of color possibilities. They use a six-digit code preceded by a hash symbol (#) and represent the amount of red, green, and blue (RGB) in the color. Each pair of digits controls the intensity of one of these primary colors, ranging from 00 (no color) to FF (full intensity).

Examples

  1. #FF0000 = Pure Red
  2. #008000 = Pure Green
  3. #0000FF = Pure Blue
  4. #FFFFFF = White
  5. #000000 = Black

Hexadecimal codes allow for over 16 million color combinations! They are the most common way to specify colors in web design due to their precision.

Shortened Hex Codes: For convenience, you can use a three-digit shortened version of hex codes where each digit is doubled (e.g., #FF0033 can be shortened to #F03).

Tip: Online color pickers and converters make it easy to find the perfect hex code or convert between different color formats. Experiment and explore those resources!

RGB and RGBA Colors

RGB and RGBA provide a numerical way of defining colors based on their red, green, and blue components.

RGB Format

It uses the rgb() function. Each color value ranges from 0 to 255, representing its intensity.

Example

				
					CSS
body {
   background-color: rgb(255, 128, 0); /* A bright orange color */
}
RGBA Format
This function adds a fourth value (alpha) to the rgba() function controlling opacity (transparency). The alpha value ranges from 0.0 (fully transparent) to 1.0 (fully opaque).
Example
CSS
p {
   color: rgba(0, 0, 0, 0.7); /* Black text with 70% opacity */
}

				
			

Why RGBA? RGBA empowers you to create semi-transparent colors, overlays, fading effects, and sophisticated designs that play with layers. It’s an essential tool for modern web designers.

Both RGB and RGBA support the use of percentages instead of numeric values (e.g. rgb(100%, 50%, 0%)). However, the numeric format is generally preferred in professional settings due to greater precision.

HSL and HSLA Colors 

HSL stands for Hue, Saturation, and Lightness. It’s a color model that offers a way to express color more aligned with how we intuitively perceive them:

Hue

The actual color on the color wheel is represented as a degree from 0 to 360:

  • 0/360 = Red
  • 120 = Green
  • 240 = Blue

Saturation

The intensity or vibrancy of the color is expressed as a percentage. 0% is grayscale, while 100% is full saturation.

Lightness

How light or dark the color is also expressed as a percentage. 0% is black, 50% is the true hue, and 100% is white.

HSLA adds the alpha channel for transparency, just like RGBA.

Example

				
					CSS
h1 {
  color: hsl(240, 100%, 50%); /* A pure blue color */
}
p {
    background-color: hsla(0, 100%, 50%, 0.8); /* A semi-transparent red */ 
} 

				
			
Why HSL/HSLA? 

HSL/HSLA is often preferred by designers because it allows you to think about color components independently. Want a slightly lighter shade of the color you’re using? Simply adjust the lightness value. Need a less saturated version? Lower the saturation. It offers a natural way to manipulate colors.

Color Manipulation in CSS

Color Functions 

CSS provides built-in functions that allow you to modify existing colors directly within your stylesheets. This dynamic approach gives you incredible flexibility. Let’s look at some key functions:

lighten() and darken(): These functions take a color and a percentage. They adjust the lightness of the original color, making it lighter or darker, respectively.

Example

				
					CSS
p {
  color: blue; 
}
p.highlight {
  color: lighten(blue, 20%); /* Creates a lighter blue for the highlighted text */
}

				
			

saturate() and desaturate() Similar to lighten and darken, these functions adjust the saturation (intensity) of a color by a percentage.

Example

				
					CSS
button {
  background-color: hsl(30, 80%, 60%); /* An orange button */
}
button:hover { 
  background-color: desaturate(hsl(30, 80%, 60%), 30%); /* A less saturated orange on hover */
}

				
			
Benefits of Color Functions: 

These functions streamline adjustments, making it easy to create variations of a base color to maintain a consistent color scheme throughout your designs.

Relative Colors 

CSS relative colors provide remarkable customization power. They allow you to define colors based on an existing color. This is incredibly useful when creating a consistent color palette or variations across elements.

How it works? You use the from keyword followed by a base color. Then, you use variables like r, g, b, and a (representing red, green, blue, and alpha) to modify parts of that base color.

Example

				
					CSS
.section-title {
  color: blue;
}
.section-title-highlight {
  color: from blue lighten(r, 20%) saturate(g, 50%); 
  /* A color derived from blue, with lighter red and more saturated green components */
}

				
			

Relative colors are particularly helpful when you need to maintain color relationships, even if a base color changes within your web design.

Note: Relative colors are a fairly recent addition to CSS, so while browser support is increasing, it’s good practice to check compatibility before using them.

CSS3 Color Manipulation Updates

While we’ve covered the core color manipulation methods, it’s worth noting that CSS3 introduced several new and exciting ways to work with colors:

  • HWB: This color model stands for Hue, Whiteness, and Blackness. It offers another way to describe colors in a human-intuitive way, which is sometimes preferred when working with color variations.
  • Lab and LCH: These color spaces are designed to represent human color perception better, offering more precision in certain contexts.
  • Color-mix () function: This function allows you to blend colors in various ways directly within CSS, similar to blend modes in image editors.

While these newer features offer additional flexibility, browser support may vary. Always check compatibility if you plan to incorporate them into your projects.

Color Contrast and Accessibility

Color choices directly impact the accessibility of your website for users with visual impairments. Sufficient contrast between text and background is essential for readability.

  • WCAG Guidelines: The Web Content Accessibility Guidelines (WCAG) define minimum contrast ratios for different text sizes and styles to ensure content is legible.
  • Contrast Checking Tools: Numerous online tools help you check contrast ratios. 

It’s worth noting that Elementor includes built-in tools and features that make accessibility easier to consider in your design process. This subtle mention aligns with our overall strategy of seamlessly weaving Elementor into the narrative.

Remember – Accessible design is not just good practice; it expands your website’s reach and inclusivity.

Color Theory for Web Designers

The Color Wheel 

The foundation of color theory lies in the color wheel. This circular diagram arranges colors based on their relationships to each other. Here’s a breakdown of its essential components:

  • Primary Colors: Red, yellow, and blue. These are the building blocks of all other colors.
  • Secondary Colors: Orange, green, and purple. It was created by mixing two primary colors.
  • Tertiary Colors are colors formed by mixing a primary and a secondary color (e.g., yellow-orange, red-violet).

Understanding the Color Wheel: The color wheel is a powerful visualization tool for understanding how colors interact and for crafting intentional color combinations.

Color Schemes 

The color wheel provides a framework for creating harmonious color palettes. Here are some widely used schemes:

Complementary

Colors directly opposite each other on the color wheel (e.g., red and green, blue and orange). These create high contrast and vibrancy.

Analogous

Colors are located next to each other on the color wheel (e.g., red, red-orange, and orange). They offer a harmonious and often relaxing feel.

Triadic

Three colors are evenly spaced around the color wheel (e.g., red, yellow, and blue). These schemes are bold and dynamic.

Split-Complementary

A variation of complementary colors in which you use the two colors adjacent to the direct opposite of your base color creates a balance of contrast and harmony.

Tetradic (or Double Complementary)

It uses two sets of complementary colors, often forming a rectangle on the color wheel. This offers a wide range of color combinations with great versatility.

Monochromatic

Variations of a single hue using different lightness and saturation values (e.g., light blue, medium blue, and dark blue). Monochromatic schemes evoke a sense of unity and elegance.

Tips

  1. Online Tools: Color scheme generators can be fantastic resources for experimentation and finding the perfect combination.
  2. Balance: While bold combinations can be striking, it’s important to strike a balance between vibrancy and visual coherence in your web design.

Color Psychology

Color choices profoundly impact how people perceive and emotionally respond to your website. Understanding color psychology empowers you to evoke specific moods and associations.

Common Color Associations (Western Culture)

  1. Red: Passion, excitement, energy, but also danger or urgency. Use strategically!
  2. Blue: Trust, reliability, calmness, professionalism. Often popular on corporate websites.
  3. Green: Nature, growth, harmony, freshness. Frequently linked to environmentally-conscious brands.
  4. Yellow: Optimism, happiness, playfulness. It can be overwhelming if used excessively.
  5. Orange: Warmth, enthusiasm, affordability. Great for calls to action.
  6. Purple: Luxury, sophistication, creativity. Often used in artistic or spiritual contexts.

Important Considerations

  1. Cultural Context: Color associations can vary across cultures. Do your research if targeting a global audience.
  2. Brand Identity: Your color choices should align with your overall brand personality and message.

A website builder like Elementor allows you to experiment with and implement color psychology. Its intuitive color pickers and flexible styling options make it easy to tailor your website’s look and feel precisely to the emotional response you want to evoke.

Advanced CSS Color Techniques

Gradients

Gradients create seamless blends between two or more colors, adding depth and visual interest to your web designs. CSS offers several types of gradients:

Linear Gradients

Colors transition in a straight line. You define a direction (e.g., “to right”, “to bottom left”), and color stops along the way.

Example
				
					CSS
background: linear-gradient(to right, red, orange, yellow);
				
			

Radial Gradients

Colors transition outwards from a central point, creating a circular or elliptical effect.

Example
				
					CSS
background: radial-gradient(blue, lightblue); 

				
			

Repeating Gradients

Create striped or patterned effects by repeating a gradient pattern.

Example
				
					CSS
background: repeating-linear-gradient(45deg, black, black 10px, white 10px, white 20px);

				
			

Tip –  Gradient Generators: Online tools make creating and customizing gradients a breeze.

Color Animations and Transitions

CSS allows you to create smooth color changes, adding a touch of interaction and visual appeal to your websites.

Transitions

Gradual changes in color properties triggered by an event, like hovering over a button (transition property).

				
					CSS
button {
   background-color: blue;
   transition: background-color 0.5s ease-in-out; 
}

button:hover {
   background-color: green;
}

				
			

Animations

More complex color changes using keyframes and the @keyframes rule to define distinct points in the animation sequence.

				
					CSS
@keyframes color-pulse {
  0% { background-color: red; }
  50% { background-color: yellow; }
  100% { background-color: red; }
}

				
			

Applications

Color animations and transitions can be used for:

  • Interactive elements (buttons, links)
  • Highlighting notifications or updates
  • Adding playful visual effects

Note: Use animations thoughtfully! Overusing them can distract rather than enhance the user experience.

CSS Filters 

CSS filters offer a powerful way to modify the appearance of elements on your website, including images, backgrounds, and even text. Here are some popular filters:

  1. grayscale(): Converts colors to shades of gray.
  2. sepia(): Applies a vintage, brownish tone.
  3. saturate(): Increases or decreases color saturation.
  4. contrast(): Adjusts the contrast between light and dark areas.
  5. brightness(): Makes colors lighter or darker.
  6. blur(): Adds a blurring effect.
  7. invert(): Inverts colors.
  8. hue-rotate(): Shifts colors along the color wheel.

Example

				
					CSS
img {
  filter: sepia(80%) blur(3px);
}
img:hover {
  filter: grayscale(0%); /* Image becomes full color on hover */
}

				
			

Tips

  1. Filters can be combined for unique effects.
  2. Use transitions to create smooth filter changes on hover or interaction.

Working with Color Variables 

CSS variables (also known as custom properties) revolutionize how you manage colors and maintain visual consistency across your websites.

How They Work

Declare

Variables are declared with two dashes () and a custom name:

				
					 CSS
:root {
  --primary-color: blue; 
  --accent-color: orange;
}

				
			
				
					CSS
h1 { 
  color: var(--primary-color);
}
button {
  background-color: var(--accent-color);
}

				
			

Benefits

  1. Centralized Control: Changing a color variable updates all uses throughout your stylesheet.
  2. Improved Readability: Meaningful variable names make your CSS easier to understand.
  3. Theming: Create different color themes by dynamically switching variable values.

Preprocessors (Sass, Less): Tools like Sass and Less extend CSS with advanced features, including color variables, nesting, and color manipulation functions. While not strictly necessary, they further streamline color workflows.

Note: CSS Variables have excellent browser support. Always check compatibility if targeting older browsers.

Choosing Colors for Your Website

Branding 

If you have an existing brand, your primary website colors should align with your brand identity. This ensures visual consistency and strengthens brand recognition. Consider these aspects:

  • Brand Personality: What emotions or qualities does your brand embody? Choose colors that reflect these traits.
  • Logo: Can you extract a dominant color scheme from your logo to use as a foundation?
  • Existing Brand Materials: Analyze your print or digital marketing materials to identify recurring color themes.

Target Audience

Understanding your target audience’s preferences and expectations is crucial for effective color choices. Consider these factors:

  • Demographics: Age and gender can influence color associations. For example, younger audiences might gravitate towards brighter, bolder palettes, while older audiences might prefer more muted tones.
  • Cultural Background: Color meanings vary between cultures. Research your target markets to avoid misinterpretations.
  • Industry and Niche: Specific industries often have conventional color associations (e.g., healthcare with blues and greens). Analyze your competitors to identify common patterns and how you can either align or differentiate yourself.

Tip: While considering your audience is vital, don’t let it completely override your brand identity. Strive for an authentic balance that resonates with your target market.

Web Design Trends

Staying aware of current web design trends can inspire fresh color palettes and keep your website looking modern. However, it’s essential to balance trendiness with timeless design principles:

  1. Trending Color Schemes: Research platforms like Dribbble or Behance to identify popular color combinations.
  2. Bold Monochromes: Using a single color in varying shades and saturations is a striking trend.
  3. Retro Palettes: Nostalgia is in! Pastels and muted tones reminiscent of specific decades can make a memorable impact.
  4. Accessibility-forward trends: Trends focusing on high-contrast, color-blind-friendly palettes are a win-win for design and inclusivity.

Don’t chase trends blindly. Choose colors that align with your brand’s long-term vision. Incorporating trendy elements as accents or in fleeting sections of your site can be a good balance.

Conclusion 

Colors hold immense power in web design. They shape the user experience, convey your brand’s identity, and influence how people perceive your website. By mastering the technical and artistic aspects of color, you’ll create visually stunning websites that resonate with your audience.

Key Takeaways:

  1. CSS provides a vast array of options for color manipulation, from basic keywords to advanced techniques like gradients and filters.
  2. Color theory and psychology are your allies when making intentional design choices.
  3. Consider branding, target audience, and current trends when crafting your color palette.

Don’t be afraid to experiment, try new combinations, and find colors that ignite your creativity.

A website builder like Elementor simplifies the process of implementing your beautiful color schemes. Its intuitive interface, color customization options, and performance-minded features streamline the web design process so you can focus on expressing your vision.