I am not able to get Customer group name using customer id in magento2.
i have customer group id but i didn't get group name.
<?php
$customerObj = $objectManager->create('Magento\Customer\Model\Customer')->getCollection()->addFieldToFilter('entity_id', $group_id);
print_r($customer_data->getCustomerData());
?>
Best Answer
Try below code :