Here a more mathematical way of seeing it, though not really complicated. IMO much clearer as informal ones:

The question is, how many times can you divide N by 2 until you have 1? This is essentially saying, do a binary search (half the elements) until you found it. In a formula this would be this:

1 = N / 2

^{x}

multiply by 2^{x}:

2

^{x}= N

now do the log_{2}:

log

_{2}(2^{x}) = log_{2}N

x * log_{2}(2) = log_{2}N

x * 1 = log_{2}N

this means you can divide log N times until you have everything divided. Which means you have to divide log N (“do the binary search step”) until you found your element.