Navigation BarTutorials

Modern navigation bar

Create a modern navigation bar

Before We Start

Modern navigation bar. A navigation bar is one of the main components of a website, It contains links to the other sections and a user interface element within a website. The most important one and the first section that the user sees when he/she enters a website is the navigation bar and it links to the other main parts.

In a website the navigation bar will be an important part and it helps the users to find the pages quickly If you have ever seen a website which doesn’t has a navigation bar, you may have found it’s not easy to locate the exact page what you need. So if you are a person who wishes to develop a website, you have to know how to create a navigation bar properly.

How to create a responsive navigation bar ? We are here to solve your problem.
In this article we discuss how to create a responsive navigation bar. Before we start please read the below articles which easier you to understand the process, if you are new to development.

Step 1 – Add HTML

It’s too easy and simple. Just copy and paste below code in your HTML editor between <body> </body> tag.

  <h2 style="text-align:center; padding-top: 50px; color: #FFF; 
    font-family: Roboto;">Modern Menu Bar ( HTML + CSS )</h2>
    <li><a class="btn1">Home</a></li>
    <li><a class="btn1">About</a></li>
    <li><a class="btn1">Blog</a></li>
    <li><a class="btn1">Contact</a></li>

Step 2 – Add CSS

Copy and paste below code in your HTML editor between <style></style> tag.


body {
  background: #006dc0; /* fallback for old browsers */
  background: -webkit-linear-gradient(
    to right,
  ); /* Chrome 10-25, Safari 5.1-6 */
  background: linear-gradient(
    to right,
  ); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */

.btn1 {
  position: relative;
  display: block;
  overflow: hidden;
  width: 100%;
  height: 80px;
  max-width: 250px;
  margin: 1rem auto;
  text-transform: uppercase;
  /*   border: 1px solid currentColor; */
  color: white;
  line-height: 80px;
  text-align: center;
  transition: ease 0.5s;
  font-family: "Nunito";
  font-size: 20px;
  box-shadow: -3px 9px 20px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);

.btn1:before {
  content: "";
  position: absolute;
  top: 0;
  right: -50px;
  bottom: 0;
  left: 0;
  border-right: 50px solid transparent;
  border-bottom: 80px solid white;
  -webkit-transform: translateX(-100%);
  transform: translateX(-100%);
  transition: cubic-bezier(1, -0.02, 0.26, 0.38) 0.5s;
  z-index: -1;

.btn1:hover {
  color: #00c3ff;

.btn1:hover:before {
  transform: translateX(0);

ul {
  margin-top: 50px;
  display: block;
  text-align: center;

ul li {
  display: inline-block;

li {
  list-style: none;
  /*   float: left; */
  width: 200px;
  margin-left: 10px;
}    </style>

At the end we will have something like this. You can change fonts, colors, backgrounds and all things that you want.Enjoy it.

Create a modern navigation bar

Video Tutorial

Please watch this video to better understand this tutorial and don’t forget to subscribe to our channel.

Help others to find out about this article on Social Media sites. If you have any doubt or any problem, don’t hesitate to contact us. Thereafter we will be able to help you and also make sure you bookmark our site on your browser.

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button