CSS Live Color Picker

The Problem

When you’re working on a web mockup in HTML, Firebug is a godsend. You can tweak CSS attributes and values and see their effects on your page immediately; it’s like sketching in CSS. However, when you want to change CSS color values, Firebug only lets you type in color hex codes; there’s no color picker. What’s up with that?

Well, it bothered me enough that I decided to hack up a little tool to let me ’sketch’ with color values in CSS.

The Solution

CSS Live Color Picker is a JavaScript bookmarklet that creates a draggable, instant-page-updating color picker over any web page.

I’m calling it CSS Live Color Picker, until I decide that I need a sexier sounding name. But who cares what it’s called? How does it work and what does it let you do?

To install CSS Live Color Picker, just drag this link to your bookmarks toolbar in Firefox or Safari (or right-click the link and bookmark it as a normal bookmark):

CSS Live Color Picker

Then just activate the bookmark to load the picker.

Notes about the picker:

Using the CSS Live Color Picker is easy:

  1. Activate the CSS Live Color Picker via the bookmark you made.
  2. Enter the name of any CSS selector (like ‘body’ or ‘.myclass’) in the CSS Selector box.
  3. Enter the name of any CSS color attribute name (like ‘background-color’ or ‘border-color’ or ‘color’) in the Attribute Name box.
  4. Using the sliders and the color box, click a color and watch as all elements that match the CSS Selector you’ve entered have their Attribute Name color property adjusted to your selected color.
  5. When you’ve found a color value you like, copy/paste its hex value from the picker into your CSS styles.

Haven’t tried it yet? Here’s what it looks like:
CSS Live Color Picker Screenshot

Easy. Awesome. Enjoy.