"

Colours

Using colour is an easy way to add visual interest to Pressbooks content. By following a few steps, it’s easy to ensure colour is used in a way that won’t exclude any readers from engaging with your Pressbook.

Hex Colour Codes

The default font colour and background for most content in Pressbooks will always be “Black” and “White.”  We must use hex colour codes to maximize the range of available colours. A hex colour code consists of a hash symbol (‘#’) followed by six hexadecimal digits. The hexadecimal number system uses 16 digits instead of 10 and includes the familiar digits ranging from 0-9, with values from 10 to 15 represented by the range ‘A’ to ‘F’ in the alphabet. Each pair of these digits represents a colour channel: the leftmost pair determines the amount of red, the middle pair determines the amount of green, and the rightmost pair represents the amount of blue. For example, #DE4226 specifies a red-orange hue.

Note that we are mixing light, not paint or dye, so black is achieved by emitting no colour (Black Hex Code #000000), while white is achieved by combining the maximum level of all colours (White Hex Code #FFFFFF).

Accessible Web Colour Contrast

Colour contrast is a numerical value for the visual difference between two adjacent colours. Sufficient colour contrast is very important to improve accessibility and can be difficult to evaluate without using a tool. This often refers to the colour contrast of the text against the background on a page but can also be applied to visual elements such as graphics, charts, and graphs.

Accessibility requirements that use “must” fall under current required accessibility guidelines. Requirements that use “should” fall under upcoming accessibility guidelines. Where possible, you should aim for this level of contrast.

  • The text must (AA) have a contrast of at least 4.5:1 for body text and 3:1 for headings.
  • The text should (AAA) have a contrast of at least 7:1 for body text and 4.5:1 for headings.
  • Adjacent colours within graphics should (2.1 AA) have a contrast of at least 3:1.
  • Colour must (AA) not be used to convey meaning. For example, additional information such as labels or symbols should also be used if colour is used in a legend.
How to Check the Colour Contrast 
Other Resources
Fixing Color Issues in Pressbooks (Video)
Design Studio Colour Palettes

Accessible Web Colour Contrast” from Accessible Digital Content Training by Jessica Blackwood and Kate Brown, © 2023 Jessica Blackwood and Kate Brown. All rights reserved.

Fixing Colour Issues” in GC Library OER Design Studio – Training – Work-in-Progress Copyright © by Jen Booth is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License, except where otherwise noted.

License

Icon for the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License

Fanshawe OER Training Guide Copyright © 2024 by Fanshawe College is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License, except where otherwise noted.