The vertical-align CSS property sets vertical alignment of an inline or table-cell box. Note that vertical-align only applies to inline and table-cell elements: you can't use it to vertically align block-level elements. Get the latest and greatest from MDN delivered straight to your inbox. Please check your inbox or your spam filter for an email from us. Help us understand the top 10 needs of Web developers and designers. Take the survey.
How to vertically center text with CSS?
CSS vertical-align property
The vertical-align property in CSS controls how elements set next to each other on a line are lined up. In order for this to work, the elements need to be set along a baseline. As in, inline e.