If you were looking at extending the DC end of a power supply (Magsafe, AC adapter, power brick), you would need to worry about the power drop over a greater length of cable. This is not because it's DC but because your electronics use relatively low voltages.
Because you are extending the AC end of your power supply, you are better off with a proper extension cable. In the same way, this is because the AC end is using higher voltages and can travel greater distance without voltage drop.
This 40ft 16AWG cable is rated for 13A at 120V, that is 1560W, while your Magsafe is less than 100W. For this length, 16AWG wire will only see a drop of about a tenth of a volt for 100W of power. That is perfectly fine. You do not want to go less than 16AWG becuase that will limit what else you can do with the cable. Be wary of any cables that do not list what size the cable is. Here is a similar cable if you only want 25ft.
The apple connectors do not specify a size or wire gauge. They are meant to supply little power over short distances. Any off brand products that go longer will probably be cheap small wires and that kind of power drop is not good for your devices or safety. If you plan to run anything heaver than a computer, or run multiple devices, I recommend a 14AWG cable. This is typically what is installed in buildings and will see much less voltage drop.
Note that any "voltage drop" in the cable is heat in the cable. Small cables over long distances are unsafe.
AWG - American Wire Gauge