The inconsistencies in your site's color palette(coderwall.com)
coderwall.com
The inconsistencies in your site's color palette
http://coderwall.com/p/u7kzua
16 comments
Although a site may have a primary color palette, colors will often look very different in context. Our vision is full of tricks and assumptions that can cause the same color value to look drastically different in different situations. The color in your swatch might look different when used on a different background color, or might not appear as bright when used as a link color, and so on. It's reasonable to expect some variation in the color palette to deal with these issues. Some of these counts seem a bit excessive, though.
Exactly. Sass/Less have functions to adjust brightness and saturation for just this reason. I routinely tweak saturation so link and hover colors "read" the same on a white background versus even a light grey header.
True. For dark text on a light background, I have often had to lighten up headlines to make the larger area match the percieved darkness of the body text. (And vice-versa.)
As a pixel artist, here’s my take on it:
You ought to choose a palette that is as small as possible while remaining versatile. Each entry should serve a distinct purpose, and should look different (and look good) next to various other entries.
For example: a mid-saturation, mid-lightness violet, say around #793D58, can be used as (1) a dark background for light elements, (2) a text or link colour on a light background, or (3) a shadow for bluish or reddish elements. Knowing how colours are perceived, and how to use them well, drastically reduces the size of a palette—the vast majority of pixel art uses fewer than 20 colours, and fewer than 10 is common.
In particular, there is usually no need to create ad-hoc colours for different contexts, such as with LESS colour transformations. These can be useful tools, but they can also create inconsistency because they take control out of your hands. And when it comes to design, I for one prefer not to leave things to chance.
You ought to choose a palette that is as small as possible while remaining versatile. Each entry should serve a distinct purpose, and should look different (and look good) next to various other entries.
For example: a mid-saturation, mid-lightness violet, say around #793D58, can be used as (1) a dark background for light elements, (2) a text or link colour on a light background, or (3) a shadow for bluish or reddish elements. Knowing how colours are perceived, and how to use them well, drastically reduces the size of a palette—the vast majority of pixel art uses fewer than 20 colours, and fewer than 10 is common.
In particular, there is usually no need to create ad-hoc colours for different contexts, such as with LESS colour transformations. These can be useful tools, but they can also create inconsistency because they take control out of your hands. And when it comes to design, I for one prefer not to leave things to chance.
Could some of the 'used once' colors just be a shading or bevel on an element of the main color? Rather than just someone picking a color that is 'close enough'.
It would be nice if results would be presented as colored boxes rather than color codes.
I'd bet part of why this happens on some of the more egregious 'offenders' (although it's arguable whether this is actually a problem or not) is the use of CSS preprocessors. It's a lot easier for a designer to add in one-off slight variations to a color when you have something like Compass or LESS's color manipulation functions.
If a site use css gradients with carefully tuned values -say, for glass buttons- they will easily "use" 5-10 colors for each gradient.
It would still look like a solid color + gloss, caustics and shadow, so from a design point of view it might be fair to treat each gradient as one "color".
It would still look like a solid color + gloss, caustics and shadow, so from a design point of view it might be fair to treat each gradient as one "color".
Exactly. My first thought, in regards to the great number of colors used by some sites, was also gradients.
How is it the site with one of the most conservative designs -- Github -- has by & large the most colors? From memory, I only see a few shades of gray when I picture the site, though I know there's a few colors that accent the UI, but hell, 331 is more than the entire old "web safe palette".
I wonder if there's some sort of anomaly or bug causing the number to be so high... perhaps they use far less images, and instead use CSS instead? Maybe they have a CSS-based color-picker somewhere in their source?
I wonder if there's some sort of anomaly or bug causing the number to be so high... perhaps they use far less images, and instead use CSS instead? Maybe they have a CSS-based color-picker somewhere in their source?
I think there is a bug. I ran it on my own site (http://nickknowlson.com) which is pretty simple in terms of colour. I got a large list of colours (33!) that contains colours I can verify are not in the stylesheet or present anywhere on the page.
EDIT: Nevermind, false alarm. Forgot about the syntax.css file for pygments.
EDIT: Nevermind, false alarm. Forgot about the syntax.css file for pygments.
Main branding colors should be consistent - where unique colors will crop up is for things like borders, hover-states, text-shadows that will not necessarily work again in another context.
Coderwall also deliberately has a slightly different color palette for each area of the site so it's not a big surprise to see our colors quickly stack up to the 44 colors the article mentions.
It might be a little excessive to have >100 colors like some of the sites mentioned.
Coderwall also deliberately has a slightly different color palette for each area of the site so it's not a big surprise to see our colors quickly stack up to the 44 colors the article mentions.
It might be a little excessive to have >100 colors like some of the sites mentioned.
This is often due to color profiles. You take a screenshot (or a mockup), grab the color, and use that value. If you didn't explicitly disable color management beforehand, you've created a new color.
Another reason are JPEGs. You get a mockup as JPEG and you use color values from that image.
I recommend to put a list of colors at the top of your primary style sheet. That's where others will look for it.
Another reason are JPEGs. You get a mockup as JPEG and you use color values from that image.
I recommend to put a list of colors at the top of your primary style sheet. That's where others will look for it.
One thing I do is start with something like 5 base colors and then in my stylesheets (with SASS), I lighten or darken those colors.
Using this analysis it would appear that we're all over the place. But in reality there are subtle changes using lighten and darken in sass to address what notJim is talking about in his comment -- "perception of color varies on size, background color, surrounding colors".
Using this analysis it would appear that we're all over the place. But in reality there are subtle changes using lighten and darken in sass to address what notJim is talking about in his comment -- "perception of color varies on size, background color, surrounding colors".
Script does not take care of images and image backgrounds.
You can use, http://cutycapt.sourceforge.net/ to render the site into png, and analyze the pixels from it.
You can use, http://cutycapt.sourceforge.net/ to render the site into png, and analyze the pixels from it.
[deleted]
Yes but one jpg of, say, a tree might contain thousands of colors and would completely throw off the data.
[deleted]
I'm surprised the author chose to visualise this data the way they did. This is crying out for a stacked bar-graph, where each 'bar' is the colour in question, and the height of the bar is the frequency.
This made me laugh. I've never heard anyone so passionately call for a stacked bar chart before - rightfully so it seems.
Good job.
Good job.
Interesting. I understand the value of keeping design simple and CSS readable, but are there performance implications (page load times, &c.) to using a large color palette?
Unlikely with modern computers and bandwidth.
HN has a orange background as inline HTML..
so actually this software it's just to extract color palette from CSS files
so actually this software it's just to extract color palette from CSS files
Yeah and several websites (google.com for instance) have their stylesheets on the HTML document to reduce the number of http requests, this program does not read them either.
It would be interesting to take this script and make it so that it does some kind of clustering, or looks at different components of the color—for example, you could just count the hues. One might expect to see a lot variation in lightness, but relatively little in hue, for example. On the other hand, maybe it's not that scientific, and designers just grab a color picker and fiddle until it looks right.