Difference between 'just' and 'only'

Solution 1:

Just refers to exactness. Only refers to uniqueness. In many cases, they are interchangeable. But not always.

In the phrases not just X … but also Y and not only X … but also Y, we mean that X is incomplete. That is, X is both inexact and non-unique, so either word will do.

On the other hand, we say only child, not ?just child, because we mean the uniqueness, not the exactness, of the child. And we say just deserts, not ?only deserts, because we mean the exactness, not the uniqueness, of the consequence.