In this section, we will learn what the margin-right property is and how to use it in CSS.
CSS margin-right Property Definition and Usage
The CSS `margin-right` property is used to set the right margin of an element in an HTML document.
CSS margin-right Property Syntax
margin-right: length|auto|initial|inherit;
CSS margin-right Property Value
The value of this property is a number with relative, or absolute units supported in CSS.
Note: you could also use the two global values “initial” and “inherit” for this property.
Example: margin-right in CSS
See the Pen margin-right in CSS by Enjoy Tutorials (@enjoytutorials) on CodePen.