CSS Intro

CSS Intro Quiz

CSS Intro Exercise

CSS Basic

CSS Basic Quiz

CSS Basic Exercise

CSS Advance

CSS Advance Quiz

CSS Advance Exercise


CSS3 Quiz

CSS3 Exercise

CSS Properties

CSS Functions

CSS Selectors

CSS hsla() Function

CSS hsla() Function



The hsla() function is used to define colors using the Hue Saturation Lightness Alpha model (HSLA). In this, H stands for Hue, S stands for Saturation, L stands for Lightness, and A  stands for Alpha. It is used basically used for changing the opacity of elements.




Its syntax is:- hsla(hue, saturation, lightness, alpha)


Further Explanation:-


Value Description
hue Defines a degree on the color circle from 0 to 360.
saturation Defines the saturation. 0% is a shade of gray and 100% is the full color.
lightness Defines the lightness; 0% is black, 50% is normal, and 100% is white.
alpha Defines the opacity between 0 and 1.

Code Explanation

All Tutorials related to CSS Functions

All Sections related to CSS