Hello Magento Friends,

Today I will be explaining How to Change Length of Order Increment ID in Magento 2.

The default value of the Increment ID is 9 digits in Magento 2. Although the Magento 2 admin can customize the size of the order increment ID in the custom module. The order increment ID can be increased or decreased according to the requirement. The customized order increment ID will also be changed for shipment, invoice, and credit memos.

Let’s discover How to Change Length of Order Increment ID in Magento 2

Steps to Change Length of Order Increment ID in Magento 2:

Step 1: Go to the below path

app\code\Vendor\Extension\etc\di.xml

And add the code as mentioned below

 Step 2: Run the below command after adding the above code

Here the length of the Increment Id will be 7 digits. However, you can place any digit as per your requirement for a customized increment number. The length of increment changed here will be the same for the invoice, shipment, and credit memo.

Implementing the above steps will increase the length of order increment ID accordingly. 

order increment id

Conclusion:

This way you can Change Length of Order Increment ID in Magento 2. The admin can also Show/Hide Order ID in Invoice, Shipment & Credit Memo PDF of Magento 2. In case of any trouble, mention in the comment part. I will be quick to solve it. Share the article with your fellow Magento colleagues and stay in touch with us!

Happy Coding!

Click to rate this post!
[Total: 7 Average: 4.4]