How can I center the header menu in the Dawn theme?

Topic summary

Users are seeking to center the header menu in Shopify’s Dawn theme, which is left-aligned by default.

Primary Solution:
Multiple contributors recommend adding CSS code to the assets/base.css file. The most common approach involves:

  • Navigating to Online Store > Themes > Actions > Edit Code
  • Opening base.css and pasting CSS at the bottom
  • Using a media query targeting screens min-width 990px
  • Modifying .header__inline-menu with properties like text-align: center and width: 100%

Alternative Method:
One user suggests editing line 1887 in base.css, changing grid-template-columns: auto auto auto to auto 1fr auto to achieve centering through grid layout adjustments.

Current Status:
The solution remains effective across Dawn theme versions 9, 10, and 13.0. Users report successful implementation in approximately 20 seconds. A video tutorial has also been shared for beginners needing visual guidance.

Summarized with AI on November 3. AI used: claude-sonnet-4-5-20250929.

@Questions1 , do this to fix it in 20 seconds:

  1. In your Shopify Admin go to: online store > themes > actions > edit code
  2. Find Asset > base.css and paste this at the bottom of the file:
@media (min-width: 990px){
    .header{
    display: flex !important;
    justify-content: space-between !important;
}
}

Kind regards,
Diego

8 Likes