Only changes in potential energy have physical significance, the absolute values that we assign to potential energies are a matter of convention – as to where in space we choose to have zero potential energy.
For example, close to the Earth, where the gravitational field is almost uniform, we may use the formula: PE=$mgh$. We could choose $h=0$ to be at the local ground level, but if we had an underground laboratory we might put $h=0$ at laboratory floor level ��� and so on.
You are concerned with the field, both close and distant, due to a spherically symmetrical body, of radius $R$, say. The work that must be supplied by an external agency to move $m$ at constant speed from $r$ to $r+dr$ is $(GMm/r^2)dr.$ If we choose to put our zero of PE on the body's surface, then the PE at distance $r_1$ from the body's centre will be
$$\text{PE}=\int_R^{r_1} \frac{GMm}{r^2} dr=GMm\left(\frac 1R - \frac 1{r_1}\right)$$
For someone based on the body's surface this does have the merit of being positive: the further we take $m$ from the body (mass $M$) the more positive the PE. And putting $r_1=R+h$ we find that for $h\ll R$, $\text{PE}= mgh$ in which $g=GM/R^2$.
For an astronomical body, we don't usually think of ourselves as being on its surface, and it's more convenient to take the zero of PE as at infinity, giving the simple formula
$$\text{PE}=\int_\infty^{r_1} \frac{GMm}{r^2} dr=-GMm\frac 1{r_1}.$$ This means that the PE as we come closer to $M$ becomes increasingly negative, rather than becoming less positive, but both formulae above give the same value for the change in PE as we take $m$ from $r_1=a$ to $r_1=b$.
What about choosing to put the zero of PE at the centre of $M$? If $M$ is a homogeneous sphere, the PE of $m$ at $r=r_1$, for $r_1>R$ is
$$\text{PE}=\int_0^{R} GM\frac{r^3}{R^3}m\frac 1{r^2} dr+\int_R^{r_1} \frac{GMm}{r^2} dr=GMm\left(\frac 3{2R} - \frac 1{r_1}\right)$$
This somewhat messy formula seems to have no advantages – especially since a homogeneous sphere is a poor model for any large astronomical body. If $M$ is a point mass, that is we consider $R$ approaching zero, the formula becomes unusable.