Length or duration?

Either word can be used in this context, and they'll be understood perfectly well. Duration is more specific to lengths of time, so it might be more appropriate. On the other hand, length is a more familiar word; using duration makes it seem more proper or technical.


Although you didn't ask about it, the previous answer correctly notes that duration isn't used for distance; from en.wiktionary, duration means “An amount of time or a particular time interval” and “The time taken for the current situation to end, especially the current war”, plus a technical finance meaning (“A measure of the sensitivity of the price of a financial asset...”).

While you can use either of duration or length (see below), a shorter word you might consider is term. From en.wiktionary, sense 11 is “Duration of a set length”.

Besides length's primary sense “The measurement of distance along the longest dimension of an object”, en.wiktionary mentions senses “duration” and (figuratively) “Total extent”.