I want to move header logo to centre and top. Search bar to the left side of screen as per show in screen shoot how can I do this using default.xml file

enter image description here


Update your move tag using below code :

app/design/frontend/{{YOUR THEME NAME HERE}}/default/Magento_Theme/layout/default.xml

<?xml version="1.0"?>
 * Copyright © 2016 Magento. All rights reserved.
 * See COPYING.txt for license details.
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        <move element="top.search" destination="header-wrapper" before="logo" />

Now, You need to update less code also :

.header.content {
    text-align: center;
    .block.block-search {
        float: left;
    .logo {
        display: inline-block;
        float: none;
    .minicart-wrapper {
        text-align: left;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.