This rule comes straight away from the definition of base.
Suppose you are given a positive integer $x$. It doesn't matter how it is written, as long as you can identify the number (in particular, the original number system doesn't matter). Now, you want to write it as
$$
x=\sum_{i=0}^{n} b_i B^i
$$
where $\{b_i\}$ are the digits of $x$ in the base $B>1$. Observe that if you divide $x=x^{(0)}$ by $B$, by Euclidean division you get
$$
x^{(0)} = r_0 + Bx^{(1)}
$$
for some (positive) integers $x^{(1)}<x^{(0)}$ and $r_0<B$. You can then recursively divide $x^{(1)}$ by $B$ (note that this will require only a finite number of steps), obtaining
$$
x=r_0+B\left(r_1+B\left(r_2+B\left(\dotso +B(r_n)\right)\right)\right)
$$
with $0\leq r_i<B$. Therefore $b_i=r_i$ as required.
You can then easily adapt this to cover negative integers and real numbers, too. Note that for a generic real number a finite number of divisions won't be enough, though.