Getting Started

Install Culori from npm

Add Culori as a dependency to your project:

npm install culori

Then start using it:

import { rgb } from 'culori';

// ⇒ Object { mode: "rgb", r: 1, g: 0.38823529411764707, b: 0.2784313725490196 }

Fetch Culori from a CDN

You can use Culori from your favorite Content Delivery Network to create quick prototypes in HTML. Here are a few popular choices:


Use it as an ES module:

<script type='module'>
import { rgb } from '';

...or using a traditional <script> tag. The library will be made available under the culori global variable:

<script src=""></script>

Use Culori online

In your browser's console

The library is added to every page of this website, so you can try the API in your browser's console as you read through the examples.


You can also use Culori in the Runkit npm playground ( to test the API without installing anything.


If you prefer to see the results visually, Observable is a great place to tinker with the library.

Add this cell and you're good to go:

culori = import('culori@2.0.3');

It's often useful to pin the library to a specific version, to make sure your old notebooks don't break if the API changes in a new major version of the library.

Use Culori in Deno

The library is published to for usage in Deno:

import { rgb } from '';