YogeshChauhan . com

How to create Glowing Text using CSS?

in CSS on January 24, 2021

We can use the text-shadow property to create the light effect around the text. After that we can increase and decrease that light effect using animation.

CSS text-shadow Property

The CSS text-shadow property adds shadow to texts.

We can add a comma separated list of values to add shadows to the text.

For example,

We can add more than one shadow to the text by adding a comma separated list of values.


To create a CSS animation, we need to style the element with the animation property/sub-properties. It will let us configure the timing, duration, and other details of how the animation sequence should progress.

We can use shorthand property to set the animation values. The syntax is:

animation: name duration timing-function delay iteration-count direction fill-mode;

We don’t need to use all sub-properties for our example.

The @keyframes Rule

To change the animation from the current style to the new style at certain times, we can specify the styles inside the @keyframes rule. We also need to bind the animation to an element.

Complete Text Glow Example


Most Read

#1 How to check if radio button is checked or not using JavaScript? #2 Solution to “TypeError: ‘x’ is not iterable” in Angular 9 #3 How to uninstall Cocoapods from the Mac OS? #4 How to add Read More Read Less Button using JavaScript? #5 How to Use SQL MAX() Function with Dates? #6 PHP Login System using PDO Part 1: Create User Registration Page

Recently Posted

May 5 Use inline if to make a shorter conditional syntax in React May 4 What is Conditional Rendering in React? May 3 How does @extend rule work in SCSS (Sass)? May 2 How different is Handling Events in React vs HTML DOM? May 2 How to create bouncing balls using HTML canvas and JavaScript? Apr 30 HTML canvas methods

You might also like these

LEFT JOIN in PostgresPostgresClearwater Seafoods – B2C in ChinaMiscHow to enable GD library support for PHP on windows server?PHPHow to make WordPress main stylesheet (style.css)?WordPressHow to Make CSS Lists Bullets Smaller?CSSFull and Partial ROLLUP in Postgresql with ExamplesPostgresHow to get recent posts in WordPress?WordPressWhat are Null Sessions?MiscWhat are Identifiers in JavaScript?JavaScriptThe actual difference between indexOf() and search() in JavaScriptJavaScriptHow to add Lifecycle Methods to a Class in React?ReactWhat’s a Strict mode in JavaScript?JavaScript