{"id":17598,"date":"2011-02-27T19:09:05","date_gmt":"2011-02-27T13:39:05","guid":{"rendered":"https:\/\/www.quickonlinetips.com\/archives\/?p=17598"},"modified":"2026-10-07T20:05:30","modified_gmt":"2026-10-07T14:35:30","slug":"disable-remove-wordpress-admin-bar","status":"publish","type":"post","link":"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/","title":{"rendered":"How to Disable the WordPress Admin Bar (for You or All Users)"},"content":{"rendered":"<p>Want to <strong>disable the WordPress admin bar<\/strong>? When WordPress 3.1 introduced the admin bar (now called the Toolbar) in 2011, many bloggers found it obtrusive on the front of their sites, and we went looking for a way to turn it off. The options have improved since. You can hide it just for yourself in your profile, for all non-admins with one line of code, or with a lightweight plugin. Here is each method for 2026.<\/p>\n<p><img decoding=\"async\" class=\"aligncenter size-full wp-image-63524\" src=\"https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/disable-wordpress-admin-bar.webp\" alt=\"How to disable the WordPress admin bar\" width=\"1200\" height=\"630\" srcset=\"https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/disable-wordpress-admin-bar.webp 1200w, https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/disable-wordpress-admin-bar-300x158.webp 300w, https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/disable-wordpress-admin-bar-1024x538.webp 1024w, https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/disable-wordpress-admin-bar-150x79.webp 150w, https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/disable-wordpress-admin-bar-768x403.webp 768w\" sizes=\"(max-width: 1200px) 100vw, 1200px\" \/><\/p>\n<p><strong>Quick answer:<\/strong> To hide it for yourself, go to <strong>Users &gt; Profile<\/strong> and untick <strong>Show Toolbar when viewing site<\/strong>. To hide it for everyone except administrators, add <code>if ( ! current_user_can( 'manage_options' ) ) { show_admin_bar( false ); }<\/code> to your child theme&#8217;s functions.php or a code snippets plugin. The Toolbar on the dashboard itself cannot be fully removed without hiding admin menus.<\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_89 counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-6ae7e8e85a2a8\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"ez-toc-cssicon\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #1a202c;color:#1a202c\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #1a202c;color:#1a202c\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-6ae7e8e85a2a8\" checked aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#What_is_the_WordPress_admin_bar\" >What is the WordPress admin bar?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Method_1_Turn_it_off_for_yourself\" >Method 1: Turn it off for yourself<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Method_2_Disable_it_for_all_non-admins_code\" >Method 2: Disable it for all non-admins (code)<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Method_3_Use_a_plugin\" >Method 3: Use a plugin<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Customize_the_admin_bar_instead\" >Customize the admin bar instead<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Why_keep_it\" >Why keep it?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Hide_the_admin_bar_on_mobile_only\" >Hide the admin bar on mobile only<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#FAQ\" >FAQ<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Why_is_there_a_gap_at_the_top_of_my_site\" >Why is there a gap at the top of my site?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Can_visitors_see_the_admin_bar\" >Can visitors see the admin bar?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/02\/disable-remove-wordpress-admin-bar\/#Will_disabling_the_admin_bar_affect_my_dashboard\" >Will disabling the admin bar affect my dashboard?<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<h2><span class=\"ez-toc-section\" id=\"What_is_the_WordPress_admin_bar\"><\/span>What is the WordPress admin bar?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>The admin bar, or Toolbar, is the dark strip at the top of your site when you are logged in. It gives quick links to the dashboard, new posts, comments, updates and plugin menus such as Rank Math or LiteSpeed Cache. Visitors who are not logged in never see it.<\/p>\n<p><img decoding=\"async\" class=\"alignnone size-full wp-image-17599\" src=\"https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/wordpress-admin-bar.png\" alt=\"WordPress admin bar on the front end\" width=\"499\" height=\"112\" srcset=\"https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/wordpress-admin-bar.png 499w, https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/wordpress-admin-bar-150x33.png 150w, https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/wordpress-admin-bar-300x67.png 300w\" sizes=\"(max-width: 499px) 100vw, 499px\" \/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"Method_1_Turn_it_off_for_yourself\"><\/span>Method 1: Turn it off for yourself<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ol>\n<li>Go to <strong>Users &gt; Profile<\/strong>.<\/li>\n<li>Untick <strong>Show Toolbar when viewing site<\/strong>.<\/li>\n<li>Click <strong>Update Profile<\/strong>.<\/li>\n<\/ol>\n<p>This only affects your own account. Each user can choose for themselves.<\/p>\n<p><img decoding=\"async\" class=\"alignnone size-full wp-image-17600\" src=\"https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/show-admin-bar.png\" alt=\"Show toolbar when viewing site option\" width=\"352\" height=\"51\" srcset=\"https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/show-admin-bar.png 352w, https:\/\/www.quickonlinetips.com\/archives\/wp-content\/uploads\/show-admin-bar-300x43.png 300w\" sizes=\"(max-width: 352px) 100vw, 352px\" \/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"Method_2_Disable_it_for_all_non-admins_code\"><\/span>Method 2: Disable it for all non-admins (code)<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Membership sites, shops and forums often hide the bar for subscribers and customers. Add this to your <strong>child theme&#8217;s<\/strong> functions.php, or better, to a snippets plugin such as <a href=\"https:\/\/wordpress.org\/plugins\/code-snippets\/\" target=\"_blank\" rel=\"noopener\">Code Snippets<\/a> or <a href=\"https:\/\/wordpress.org\/plugins\/insert-headers-and-footers\/\" target=\"_blank\" rel=\"noopener\">WPCode<\/a>:<\/p>\n<pre><code>add_action( 'after_setup_theme', function () {\r\n    if ( ! current_user_can( 'manage_options' ) ) {\r\n        show_admin_bar( false );\r\n    }\r\n} );<\/code><\/pre>\n<p>To hide it for everyone, including administrators, use:<\/p>\n<pre><code>add_filter( 'show_admin_bar', '__return_false' );<\/code><\/pre>\n<h2><span class=\"ez-toc-section\" id=\"Method_3_Use_a_plugin\"><\/span>Method 3: Use a plugin<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>If you prefer settings to code, small plugins such as <a href=\"https:\/\/wordpress.org\/plugins\/hide-admin-bar-based-on-user-roles\/\" target=\"_blank\" rel=\"noopener\">Hide Admin Bar Based on User Roles<\/a> let you choose roles in a settings page. Some membership and WooCommerce plugins include the same option. The old plugins from our 2011 list, like WP Admin Bar Removal and WP Custom Admin Bar, are no longer maintained, so avoid them.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Customize_the_admin_bar_instead\"><\/span>Customize the admin bar instead<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Often the problem is clutter, not the bar itself. Many plugins add their own menus; check their settings for a &#8220;show in admin bar&#8221; option and turn it off. Developers can remove individual items with <code>$wp_admin_bar-&gt;remove_node()<\/code> in the <code>admin_bar_menu<\/code> hook. Fewer items also mean fewer scripts on the front end for logged-in users.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Why_keep_it\"><\/span>Why keep it?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>For site owners, the Toolbar is handy: one click to edit the post you are viewing, purge the cache or see pending comments. If you write a lot, it saves trips to the dashboard. Hide it only where it gets in the way, such as when checking your design as visitors see it.<\/p>\n<p>More WordPress tweaks: <a href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/06\/delete-post-revisions-in-wordpress\/\">delete post revisions<\/a>, <a href=\"https:\/\/www.quickonlinetips.com\/archives\/2007\/11\/how-to-create-multiple-dynamic-sidebars-for-wordpress-widgets\/\">create multiple sidebars<\/a>, and <a href=\"https:\/\/www.quickonlinetips.com\/archives\/2011\/03\/increase-wordpress-security\/\">increase WordPress security<\/a>.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Hide_the_admin_bar_on_mobile_only\"><\/span>Hide the admin bar on mobile only<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>On phones the Toolbar takes a bigger share of the screen, and its menus are harder to tap. If you only want it gone on small screens, a little CSS in Appearance, Customize, Additional CSS does the job: <code>@media (max-width: 782px) { #wpadminbar { display: none; } html { margin-top: 0 !important; } }<\/code>. This hides the bar visually for logged-in users on phones while keeping it on desktop, where it is most useful.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"FAQ\"><\/span>FAQ<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<h3><span class=\"ez-toc-section\" id=\"Why_is_there_a_gap_at_the_top_of_my_site\"><\/span>Why is there a gap at the top of my site?<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>WordPress adds 32px of space for the Toolbar when you are logged in. It disappears for visitors and when you disable the bar.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Can_visitors_see_the_admin_bar\"><\/span>Can visitors see the admin bar?<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>No. Only logged-in users see it.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Will_disabling_the_admin_bar_affect_my_dashboard\"><\/span>Will disabling the admin bar affect my dashboard?<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>No. These methods hide it on the front of the site only; the dashboard still works normally.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Want to disable the WordPress admin bar? When WordPress 3.1 introduced the admin bar (now called the Toolbar) in 2011,&#8230;<\/p>\n","protected":false},"author":4,"featured_media":63524,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_kad_post_transparent":"default","_kad_post_title":"default","_kad_post_layout":"default","_kad_post_sidebar_id":"","_kad_post_content_style":"default","_kad_post_vertical_padding":"default","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"_kad_post_classname":"","footnotes":""},"categories":[6],"tags":[49,17],"class_list":["post-17598","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blogging","tag-tutorials","tag-wordpress"],"_links":{"self":[{"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/posts\/17598","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/comments?post=17598"}],"version-history":[{"count":1,"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/posts\/17598\/revisions"}],"predecessor-version":[{"id":63525,"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/posts\/17598\/revisions\/63525"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/media\/63524"}],"wp:attachment":[{"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/media?parent=17598"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/categories?post=17598"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.quickonlinetips.com\/archives\/wp-json\/wp\/v2\/tags?post=17598"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}