This is a pure CSS header pinline (also known as "line-on-sides") . The goal of this snippet is to use as little DOM elements as possible, not require any specific header height or font size, and to account for any length of header text. Most other solutions I've seen have limitations. Design for this codepen blatantly ripped off from HelloHappy .