.hexagon {
position: relative;
width: 100px;
height: 57.74px;
background-color: #6a08ca;
margin: 28.87px 0;
}
.hexagon:before,
.hexagon:after {
content: "";
position: absolute;
width: 0;
border-left: 50px solid transparent;
border-right: 50px solid transparent;
}
.hexagon:before {
bottom: 100%;
border-bottom: 28.87px solid #6a08ca;
}
.hexagon:after {
top: 100%;
width: 0;
border-top: 28.87px solid #6a08ca;
}
<div class="hexagon"></div>