Simply put, Mayweather is the better boxer. McGregor is much better in terms of UFC/MMA. When they were grabbed, McGregor kept doing hammer punches which is acceptable in UFC but not boxing. One time McGregor was about to throw him to the ground.
Put Mayweather in the octagon and watch as McGregor throws his ass on the ground, kicking till no tomorrow. Boxing is a much longer going fighting, while MMA is quick, fast action. The reason McGregor lost so easily was because he still had the MMA mindset, of quick, fast action. Mayweather knew he would get tired easily simply because McGregor is a MMA fighter, not a boxer.
It was a fun match to watch, but if it was vice versa (Mayweather in the octagon), McGregor would've won easily.