CSS borderspacing Property (original) (raw)
CSS border-spacing Property
Last Updated : 26 Aug, 2024
The **border-spacing Property is used to set the distance between the borders of neighboring cells in the Table. This property works only when the border-collapse property is set to no-collapse separate.
**Default Value: 2px
**Syntax:
border-spacing: length|initial|inherit;
**Property values:
- **length-length: It is used to set the distance between the borders of adjacent cells. It does not allow negative values.
- If two values are defined, the first value defines the horizontal space and the second value defines the vertical spacing.
- If only one value is given then it defines the both horizontal and vertical spacing between the adjacent borders of cells.
- **initial: It sets the property to its default value.
**Syntax:
border-spacing:initial;
**Example:
html `
border-spacing property