I found the answer here, in section **4.4. less (1)**.
to use it with the movement keys, have this plain ASCII file `.lesskey` in your home directory:
^[[A back-line
^[[B forw-line
^[[C right-scroll
^[[D left-scroll
^[OA back-line
^[OB forw-line
^[OC right-scroll
^[OD left-scroll
^[[6~ forw-scroll
^[[5~ back-scroll
^[[1~ goto-line
^[[4~ goto-end
^[[7~ goto-line
^[[8~ goto-end
then run the command `lesskey`. (These are escape sequences for vt100-like terminals.) This creates a binary file `.less` containing the key bindings.