I was in a store just this week setting up a plan and the sales clerk pulled out a Samsung phone and it had an unlock key on the box. My 2016 model also had an unlock key on the box and it had to be re-entered when I changed plans. Sounds like no lon...
On most samsung phones the unlock code is listed on the box the phone was purchased in. Other companies do the same. If you do not have the box or the manufacturer does not do this, you will have to contact the manufacturer.