Change checkout steps order in Magento checkout

Change checkout steps order in Magento checkout

July 13, 2026 · Illustrated author avatarBy Stefan Bogdanescu
Change checkout steps order in Magento checkout

Changing the checkout steps order is indeed possible in Magento, but it requires some customization of the checkout process. By default, Magento follows a specific checkout flow for security and compliance reasons.

To achieve your desired checkout steps sequence (Shipping address → Delivery methods → Billing address), you’ll need to override the core checkout files and implement your own logic.

Here are the general steps involved:

  1. Create a Custom Checkout Module First, create a custom module in your Magento installation. This will help you organize your changes and maintain them across upgrades. You can follow our guide on creating a custom Magento 2 module for step-by-step instructions.

  2. Override the Checkout Layout File In your custom module, create an etc folder with a view_frontend_layout.xml file inside it. This file will allow you to override the default checkout layout.

    <?xml version="1.0" encoding="UTF-8"?>
    <layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/layout_generic.xsd">
        <update handle="checkout_agreements"/>
        <referenceContainer name="checkout_steps">
            <!-- Move steps here -->
            <block class="Magento\Checkout\Block\Steps" template="Magento_Checkout::step/billing.phtml" after="-" />
        </referenceContainer>
    </layout>
    
  3. Create a Custom Checkout Step Block Create a new block in your custom module to handle the billing step logic. This block should extend Magento\Checkout\Block\Steps.

    <?php
    
    namespace LaravelCompany\CustomCheckout\Block;
    
    use Magento\Framework\View\Element\Template;
    use Magento\Checkout\Block\Steps as CheckoutSteps;
    
    class CustomBillingStep extends Template implements \Magento\Framework\App\ActionInterface
    {
        protected $template = 'Magento_Checkout::step/billing.phtml';
        protected $_context;
        protected $_registry;
        protected $_checkoutSession;
    
        public function __construct(
            \Magento\Framework\App\Action\Context $context,
            \Magento\Framework\Registry $registry,
            \Magento\Checkout\Model\Session $checkoutSession
        ) {
            $this->_context = $context;
            $this->_registry = $registry;
            $this->_checkoutSession = $checkoutSession;
            parent::__construct($context);
        }
    
        public function getStepData()
        {
            // Implement your custom billing step logic here
        }
    }
    

Remember to configure the XML layout file and the block template to include the necessary JavaScript and CSS files for the new step.

  1. Configure the Checkout Step Order In your view_frontend_layout.xml file, you can use the <referenceContainer> tag to insert your custom billing step after the appropriate checkout steps (shipping_address or delivery_methods).

In conclusion, changing the Magento 2 checkout steps order is not a straightforward task and requires significant customization of the core files. However, by following these steps and creating a new module with custom layout and block templates, you can achieve your desired checkout flow.

Always remember to backup your data before making any changes to the core files, as they may affect the performance and security of your store.

For more advanced Magento 2 development topics like this one, consider visiting our Laravel Company Blog for detailed tutorials and best practices.

Magento 2 Checkout Security Extensions

Our network