Smallest AWG copper gauge that meets both voltage-drop and ampacity requirements
Use 8 AWG copper wire for this 24V run.
Next stepConsider going one gauge larger to reduce heat and drop, especially for long continuous-duty runs.