New to Telerik UI for ASP.NET MVC? Download free 30-day trial

Contrast Tool

The Color Contrast Tool is available for the Telerik UI for ASP.NET MVC ColorPicker as of the R3 SP1 of 2021 release. It provides the option for checking the color contrast ratio between two colors. Color contrast between text and background is important on web pages. It affects some people’s ability to perceive the information. The tool follows the WCAG recommendations for web accessibility.

According to the WCAG standard, there are two levels of contrast ratio:

  • AA (minimum contrast)—The level AA requires a contrast ratio of at least 4.5:1 for normal text.
  • AAA (enhanced contrast)—The level AAA requires a contrast ratio of at least 7:1 for normal text.

The example below demonstrates how to enable the contrast tool in the ColorPicker:

    <div class="demo-section">
        <div class="column">
            <h3 class="title"><label for="picker">Foreground Color</label></h3>
        <div class="column">
            <h3 class="title"><label for="picker">Background Color</label></h3>
                .Views(new string[] { "gradient"})

        function onChange(e) {
            var foregroundPicker = $("#foreground-picker").data("kendoColorPicker")

        .demo-section {
            display: inline-flex;
            width: 100%;
            box-sizing: border-box;

        .column {
            text-align: center;

See Also

In this article