Hamburger Button Generator
This tool outputs code for a hamburger menu button.
The size and color of the three lines icon can be customized.
Use JavaScript to change the icon to a cross (x) when the menu is opened.
The output code can be easily used by copy and paste.
Sponsored Links
Start customizing from templates
(*Current customizations will be reset)
Customization
Preview
Clicking the button toggles the state of the menu when it is opened or closed
<button id="menuButton" type="button" class="menu-button" aria-labelledby="menuButtonLabel">
<span class="menu-button__line">
<span id="menuButtonLabel" style="display: none">Menu Button</span>
</span>
</button>
Notes
- It is intended for use with modern browsers and may contain CSS properties that are not supported by IE or older versions of browsers.
- The reset CSS of this site is based on “modern-normalize.css”. Depending on the reset CSS and other stylesheets loaded in your project, there may be differences from the preview appearance.
Sponsored Links
Tools
CSS Generators
Speech Bubble CSS Generator
Triangle CSS Generator
Arrow CSS Generator
Dotted & Dashed Border CSS Generator
Text Highlighter CSS Generator
Gradient Background CSS Generator
Striped Background CSS Generator
Polka Dots Background CSS Generator
Plaid & Checkerboard Background CSS Generator
Glassmorphism CSS Generator
Claymorphism CSS Generator