CSS | repeating-radial-gradient() Function
The repeating-radial-gradient() function is an inbuilt function in CSS which is used to repeat radial gradients.
Syntax:
background-image: repeating-radial-gradient(shape size at position, start-color, ..., last-color);
Parameters: This function accepts many parameters which are listed below:
- shape: This parameter is used to define the shape of gradient. It has two possible value circle or ellipse. The default shape value is ellipse.
- size: This parameter is used to define the size of gradient. The possible value are: farthest-corner (default), closest-side, closest-corner, farthest-side.
- position: This parameter is used to define the position of gradient. The default value is center.
- start-color, …, last-color: This parameter is used to hold the color value followed by its optional stop position.
Below example illustrates the repeating-radial-gradient() function in CSS:
Example:
<!DOCTYPE html> <html> <head> <title>CSS Gradients</title> <style> #main { height: 250px; width: 600px; background-color: white; background-image: repeating-radial-gradient(blue, white 10%, green 15%) } .gfg { text-align:center; font-size:40px; font-weight:bold; padding-top:80px; } .geeks { font-size:17px; text-align:center; } </style> </head> <body> <div id="main"> <div class = "gfg">GeeksforGeeks</div> <div class = "geeks">A computer science portal for geeks</div> </div> </body> </html> |
chevron_right
filter_none
Output:

Example 2:
<!DOCTYPE html> <html> <head> <title>CSS Gradients</title> <style> #main { height: 400px; width: 400px; background-color: white; background-image: repeating-radial-gradient(circle, blue, white 10%, green 15%) } .gfg { text-align:center; font-size:40px; font-weight:bold; padding-top:170px; } .geeks { font-size:17px; text-align:center; } </style> </head> <body> <div id="main"> <div class = "gfg">GeeksforGeeks</div> <div class = "geeks">A computer science portal for geeks</div> </div> </body> </html> |
chevron_right
filter_none
Output:

Recommended Posts:
- How to get the function name from within that function using JavaScript ?
- D3.js | d3.map.set() Function
- p5.js | nf() Function
- p5.js | min() function
- p5.js | red() function
- p5.js | hue() function
- D3.js | d3.max() function
- p5.js | max() function
- p5.js | abs() function
- PHP | Ds\Map xor() Function
- p5.js | nfs() Function
- PHP | pos() Function
- p5.js | sq() function
- PHP | key() Function
- p5.js | pow() function
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.




