Home » Web Design and Development » Content Management System » Wordpress » How to disable WordPress Admin Bar ?

How to disable WordPress Admin Bar ?

Sometimes, we want to make sure default wordpress admin bar ( as it looks below ) is not visible to everyone but have users register to our blog.

Admin Bar

To, disable this, there are multiple ways, but the most easiest way we could identify is to disable this using CSS, identify a code “wpadminbar” some like below,

#wpadminbar{
    direction:ltr;
    color:#ccc;
    font:400 13px/32px "Open Sans",sans-serif;
    height:32px;
    position:fixed;
    top:0;
    left:0;
    width:100%;
    min-width:600px;
    z-index:99999;
    background:#23282d;
}

from wp-includes/css/admin-bar.min.css of your wordpress code, and add following code to end of this, like as below,

#wpadminbar{
    direction:ltr;
    color:#ccc;
    font:400 13px/32px "Open Sans",sans-serif;
    height:32px;
    position:fixed;
    top:0;
    left:0;
    width:100%;
    min-width:600px;
    z-index:99999;
    background:#23282d;
    display:none;
}

i.e. we just added “display:none” in css so that the admin bar will get hidden using css.

Now, save and upload to your server and observe that wordpress admin bar is gone 🙂


Subscribe our Rurban Life YouTube Channel.. "Rural Life, Urban LifeStyle"

Leave a Comment