Get order id by increment id Magento 2

In this article, I will show you how you can load order by increment id in Magento 2 We can use the order interface Magento\Sales\Api\Data\OrderInterface to load order by increment id. By Object Manager: $objectManager = \Magento\Framework\App\ObjectManager::getInstance(); $incrementId = "100009633"; $orderInterface = $objectManager->create('Magento\Sales\Api\Data\OrderInterface'); $order = $orderInterface->loadByIncrementId($incrementId); // Print Order Object print_r($order->debug()); // Get Order Id…

Continue Reading
Close Menu