Let $(X,d)$ be a locally compact metric space.
(For every $x$ in $X$, there exists a ball centred in $x$ whose closure is compact.)Let $(Y, δ)$ be its completion. I search to prove that $(X,d)$ is isometric to an open subset of $(Y,δ)$.
I tried to prove that $φ(Χ)$ is open , where $φ$ is the isometric injection of the proposition of the existence of a completion. And to use that the range of a compact is compact.
Your idea is good: $\varphi(X)$ is indeed open in $Y$. Let $r>0$ be such that $B_r^X(x)(=\{x'\in X\,|\,d(x,x')\leqslant r\})$ is a compact neighborood of $x$ (in $X$). Then $\varphi\left(B_r^X(x)\right)$ is a compact subset of $Y$ and therefore it cannot contain any element $y\in Y\setminus\varphi(X)$, because $y$ would be the limit of a sequence $(x_n)_{n\in\mathbb N}$ of elements of $U$ and, since $U$ is compact, that sequence has a subsequence $(x_{n_k})_{k\in\mathbb N}$ which converges, at the same time, to $y(\notin\varphi(X))$ and to an element of $B_r^X(x)(\subset X)$. By the same argument, $B_r^X(x)=B_r^Y(x)$.
So, $x\in B_r^Y(x)$ and $B_r^Y(x)\subset\varphi(X)$. Since this takes place for each $x\in X$, $\varphi(X)$ is an open subset of $Y$.