How to create a skill bar with CSS?

To create a skill bar with CSS, the code is as follows −


 Live Demo

<!DOCTYPE html>
<meta name="viewport" content="width=device-width, initial-scale=1" />
   * {
      box-sizing: border-box;
   body {
      font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
   h1 {
      text-align: center;
   .container {
      width: 100%;
      background-color: rgb(231, 231, 231);
      border-radius: 20px;
   .cpp, .java, .python, .c {
      text-align: center;
      font-weight: bolder;
      padding-top: 3px;
      padding-bottom: 3px;
      color: white;
      border-radius: 20px;
   .cpp {
      width: 90%;
      background-color: #4caf50;
   .java {
      width: 80%;
      background-color: #2196f3;
   .python {
      width: 65%;
      background-color: #f44336;
   .c {
      width: 60%;
      background-color: #808080;
<h1>Programming Proficiency</h1>
<div class="container">
<div class="python">75%</div>
<div class="container">
<div class="java">70%</div>
<div class="container">
<div class="cpp">60%</div>
<div class="container">
<div class="c">40%</div>


The above code will produce the following output −