The Irish fighter became the Ultimate Fighting Championship's first dual division champion in November.
McGregor, 28, has said he wants $100m (£80m) to meet Mayweather, who has played down the prospects of a fight.
The licence has been granted by the California State Athletic Commission, allowing him to box in the US state.
McGregor's trainer John Kavanagh has said he would "put a few quid" on a bout with the retired Mayweather, 39, taking place next year.
He added: "Is it getting any closer? I don't know, but it certainly wouldn't surprise me that it's going to happen."
Leonard Ellerbe, chief executive of Mayweather Promotions, told ESPN the fight could not take place as McGregor is under contract to the UFC.
"He got a boxing licence. Congratulations to him," said Ellerbe.
"Conor McGregor can say anything he wants to, but he has a boss and his name is [UFC president] Dana White."
McGregor beat Eddie Alvarez last month to win to win the lightweight championship, to add his featherweight title, though he has since relinquished that belt.
After the Alvarez victory, McGregor demanded a stake in the ownership of UFC.
BBC Sport boxing pundit Steve Bunce
In a boxing ring with 10 ounce boxing gloves and no head guards, Conor McGregor would not touch Floyd Mayweather. In fact, I think he would struggle to touch a thousand of the 2,186 registered welterweights registered in the world.
When you see him try to box, his feet are terrible - that is mark one against him. He lifts his chin up in the air when he throws a punch - that is mark two. And when he gets hit with a punch he turns his head - that is mark three.
Just because he is the most marketable, most sellable and most entertaining fighter in the UFC business does not mean he can hold his hands up and survive with any of the boxers out there.
UFC champion Conor McGregor moved closer to a possible fight with five-weight world champion Floyd Mayweather by securing a boxing licence.