I'm know this topic has been covered thousands of times but I can't find a good explanation to what I'm looking at. I am putting in a basement bathroom, I'm wiring it now on a 20 Amp circuit per code, and today my bathroom fan and vanity lights came. They have #14 stranded wire in them. I have #12 wire from the breaker. Can I wire these lights into my circuit? I guess what has me stumped is why they would build these units with smaller wire when a bathroom is required to be protected by a 20 amp circuit. Any help would be appreciated. Thank you
That's perfectly fine. The device wiring is based on the device requirements and 14 (sometimes smaller!) is fine if designed tested and certified (UL) appropriately.
Code requirements are based on the total circuit load which may vary as attached devices change and therefore must be the right match of wire and breaker.
The Code doesn't deal with wiring that's an integral part of equipment
The NEC ampacity rules do not apply to wiring that is an integral part of equipment, as stated in 310.1:
310.1 Scope. This article covers general requirements for conductors and their type designations, insulations, markings, mechanical strengths, ampacity ratings, and uses. These requirements do not apply to conductors that form an integral part of equipment, such as motors, motor controllers, and similar equipment, or to conductors specifically provided for elsewhere in this Code.
Instead, the UL standards for various pieces of equipment govern wire sizing within that equipment, either based on engineering calculations, standard rules, or actual temperature rise tests.