How to add a comment field to Magento 2 checkout?
If you want to allow customers to leave notes to orders in text, then you can add a comment field to the Magento 2 checkout. It can be done with the use of the Order Attributes extension.
How to enable Magento 2 checkout comments?
Step 1. Navigate to Stores > Configuration > Amasty Extensions > Order Attributes and configure the shown settings.
Step 2. Navigate to Sales > Manage Order Attributes > Click the Add New Order Attribute button to create a new attribute.
Step 3. Set the attribute label to be displayed on the frontend in the Default Label parameter.
Step 4. After that, set the Attribute Code to be internally used.
Step 5. In the next window, choose the Store View for which the attribute will be active.
Step 6. Choose Customer Groups to show the attribute to.
Step 7. Choose the Text Area option in the Frontend Input Type to add a comment field to Magento 2 checkout.
Step 8. In all other settings, choose whether to enable them or not, depending on your needs, and specify the sort order for the display of attributes on the frontend.
Step 9. Then switch to the Title, Tooltip, Options and specify an attribute name for each store view for which it is enabled in the Manage Titles. In the Manage Tooltip setting, you need to specify the tooltip to be displayed next to the attribute on the frontend.
Step 10. Go to the Shipping Methods section and select a method to show the additional attribute only to those clients who have selected the specified methods.
Don’t forget to flush your cash.