In Magento, System Configurations have always stood apart from an extension that controls & contains tons of options. It’s like the heart of the extension that allows the store owner to handle all features & functionality seamlessly. Till today, we have created 100+ extensions and we are always focused to create admin configurations simple but effective the way love store owners willing to have. Because at the end of the day, it made for a store owner to reduce their efforts to maintain the store and deliver great user experience towards their store customer.

In Magento 2, it allows the developer to add tons of elements to admin interface like text files, radio buttons, dropdowns, and multiple selects, simple fields, images and more. We used to play with these system controls to fulfill each requirement we get. Even, we have published tons of article on adding various elements to system configuration and here is another for adding Radio button in the Admin System Configuration.

To add a radio button control to system configuration, you simply need to add an element by modifying ‘System.xml‘ by adding below code.
app\code\Vendor\Extension\etc\Adminhtml\system.xml

Now create another file and named it ‘Radiobtn.php‘ and paste your own logic.
app\code\Vendor\Extension\Model\Config\Source\Radiobtn.php

Also, you can play & manipulate with these codes according to your need of adding one or more radio button choices inside the Magento System Configuration.
Lastly, smash that stars if you love reading our blogs and comment down below if you are facing an issue while using this code.
Happy Coding!

Click to rate this post!
[Total: 13 Average: 3.5]