[proofplan]
We construct local smooth unitary frames by applying the Hermitian Gram-Schmidt procedure to arbitrary local complex frames. A local unitary frame identifies each fibre of $\operatorname{Fr}_U(E,h)$ with $U(r)$ by right composition. These identifications give smooth local trivializations, and on overlaps the transition functions are smooth and $U(r)$-valued because they compare two orthonormal bases of the same Hermitian [vector space](/page/Vector%20Space).
[/proofplan]
[step:Declare the structure group and dispose of the zero rank case]
Throughout the proof, $U(r)$ denotes the unitary group
\begin{align*}
U(r):=\{A\in GL(r,\mathbb C): (Az,Aw)_{\mathbb C^r}=(z,w)_{\mathbb C^r}\text{ for all }z,w\in\mathbb C^r\}.
\end{align*}
We use the convention that every Hermitian [inner product](/page/Inner%20Product) is complex-linear in the first argument and conjugate-linear in the second argument. Let $I_r\in GL(r,\mathbb C)$ denote the identity matrix. Equivalently, after identifying $GL(r,\mathbb C)$ with the open subset of complex $r\times r$ matrices with non-zero determinant, $U(r)=\{A\in GL(r,\mathbb C):A^*A=I_r\}$.
If $r=0$, then each fibre $E_p$ is the zero complex vector space, each fibre of $\operatorname{Fr}_{\mathbb C}(E)$ consists of the unique complex-linear isomorphism $\mathbb C^0\to E_p$, and $U(0)=\{I_0\}$. Hence $\operatorname{Fr}_U(E,h)=\operatorname{Fr}_{\mathbb C}(E)$ is the corresponding smooth principal $U(0)$-subbundle. For the remainder of the proof assume $r\geq 1$.
[/step]
[step:Produce smooth local unitary frames from arbitrary complex frames]
Let $p_0\in M$. Since $E\to M$ is a smooth complex vector bundle of rank $r$, there is an open neighbourhood $V\subset M$ of $p_0$ and a smooth local complex frame
\begin{align*}
e_1,\dots,e_r:V\to E
\end{align*}
such that $e_i(p)\in E_p$ and $(e_1(p),\dots,e_r(p))$ is a complex basis of $E_p$ for every $p\in V$.
We define smooth sections
\begin{align*}
v_1,\dots,v_r:V\to E
\end{align*}
recursively. First set
\begin{align*}
v_1(p):=\frac{e_1(p)}{h_p(e_1(p),e_1(p))^{1/2}}.
\end{align*}
The denominator is a positive smooth real-valued function on $V$, because $e_1(p)\neq 0$ and $h_p$ is positive definite.
Assume that $v_1,\dots,v_{k-1}:V\to E$ have been constructed smoothly and are $h$-orthonormal in each fibre. Define the section $w_k:V\to E$ pointwise by
\begin{align*}
w_k(p):=e_k(p)-\sum_{j=1}^{k-1}h_p(e_k(p),v_j(p))v_j(p).
\end{align*}
The section $w_k$ is smooth because $h$ and the sections already constructed are smooth. For each $p\in V$, the vector $w_k(p)$ is orthogonal to $v_1(p),\dots,v_{k-1}(p)$: for $1\le \ell<k$,
\begin{align*}
h_p(w_k(p),v_\ell(p))=h_p(e_k(p),v_\ell(p))-\sum_{j=1}^{k-1}h_p(e_k(p),v_j(p))h_p(v_j(p),v_\ell(p))=0.
\end{align*}
Also $w_k(p)\neq 0$. If $w_k(p)=0$, then $e_k(p)$ would lie in the span of $v_1(p),\dots,v_{k-1}(p)$, which equals the span of $e_1(p),\dots,e_{k-1}(p)$, contradicting the [linear independence](/page/Linear%20Independence) of the frame $e_1(p),\dots,e_r(p)$. Hence $h_p(w_k(p),w_k(p))>0$, and we may set
\begin{align*}
v_k(p):=\frac{w_k(p)}{h_p(w_k(p),w_k(p))^{1/2}}.
\end{align*}
This defines a smooth section $v_k:V\to E$.
By induction, $v_1,\dots,v_r$ are smooth sections and form an $h$-orthonormal complex basis of $E_p$ for every $p\in V$.
[guided]
We begin with an arbitrary smooth complex frame because vector bundles are locally trivial. Thus, after shrinking to an open neighbourhood $V\subset M$ of the chosen point $p_0$, we have smooth sections
\begin{align*}
e_1,\dots,e_r:V\to E
\end{align*}
whose values form a basis of each fibre $E_p$.
The goal is to replace this frame by one that is orthonormal for the Hermitian metric $h$. We use the Hermitian Gram-Schmidt construction, and the point that must be checked in the bundle setting is smoothness in $p$. Define
\begin{align*}
v_1(p):=\frac{e_1(p)}{h_p(e_1(p),e_1(p))^{1/2}}.
\end{align*}
Since $e_1(p)\neq 0$ and $h_p$ is positive definite, the function $p\mapsto h_p(e_1(p),e_1(p))$ is strictly positive. It is smooth because $h$ and $e_1$ are smooth. Therefore its positive square root is smooth, and $v_1$ is a smooth section.
Now suppose $v_1,\dots,v_{k-1}$ have already been constructed smoothly and are orthonormal in each fibre. To remove the component of $e_k(p)$ along the span of the earlier vectors, define the section $w_k:V\to E$ pointwise by
\begin{align*}
w_k(p):=e_k(p)-\sum_{j=1}^{k-1}h_p(e_k(p),v_j(p))v_j(p).
\end{align*}
Every coefficient $p\mapsto h_p(e_k(p),v_j(p))$ is smooth, so $w_k$ is smooth. For $1\le \ell<k$, orthonormality gives
\begin{align*}
h_p(w_k(p),v_\ell(p))=h_p(e_k(p),v_\ell(p))-\sum_{j=1}^{k-1}h_p(e_k(p),v_j(p))h_p(v_j(p),v_\ell(p))=0.
\end{align*}
Thus $w_k(p)$ is orthogonal to the previously constructed vectors.
We also need $w_k(p)$ never to vanish, otherwise normalization would fail. If $w_k(p)=0$, then $e_k(p)$ lies in the span of $v_1(p),\dots,v_{k-1}(p)$. Since the Gram-Schmidt construction never changes the span at each stage, this is the same as the span of $e_1(p),\dots,e_{k-1}(p)$. That contradicts the fact that $e_1(p),\dots,e_r(p)$ is a basis. Hence $w_k(p)\neq 0$, so $h_p(w_k(p),w_k(p))>0$. We may therefore define
\begin{align*}
v_k(p):=\frac{w_k(p)}{h_p(w_k(p),w_k(p))^{1/2}}.
\end{align*}
Again the denominator is a positive smooth real-valued function, so $v_k$ is smooth. Induction gives a smooth local frame $v_1,\dots,v_r$ that is orthonormal for $h$ in every fibre.
[/guided]
[/step]
[step:Use a local unitary frame to trivialize the unitary frame bundle]
Let $V\subset M$ be an [open set](/page/Open%20Set) carrying a smooth local $h$-unitary frame $v_1,\dots,v_r:V\to E$. Define, for each $p\in V$, the complex-[linear map](/page/Linear%20Map)
\begin{align*}
u_{p,0}:\mathbb C^r\to E_p,\qquad u_{p,0}(z_1,\dots,z_r):=\sum_{i=1}^r z_i v_i(p).
\end{align*}
Since $v_1(p),\dots,v_r(p)$ is an $h_p$-[orthonormal basis](/page/Orthonormal%20Basis), $u_{p,0}$ is a unitary isomorphism from $(\mathbb C^r,(\cdot,\cdot)_{\mathbb C^r})$ to $(E_p,h_p)$.
Define
\begin{align*}
\Phi_V:V\times U(r)\to \operatorname{Fr}_U(E,h)|_V,\qquad \Phi_V(p,A):=u_{p,0}\circ A.
\end{align*}
For $A\in U(r)$ and $z,w\in \mathbb C^r$,
\begin{align*}
h_p(\Phi_V(p,A)z,\Phi_V(p,A)w)=h_p(u_{p,0}(Az),u_{p,0}(Aw))=(Az,Aw)_{\mathbb C^r}=(z,w)_{\mathbb C^r},
\end{align*}
so $\Phi_V(p,A)\in \operatorname{Fr}_U(E,h)_p$.
The map $\Phi_V$ is fibrewise bijective. If $u\in \operatorname{Fr}_U(E,h)_p$, define
\begin{align*}
A:=(u_{p,0})^{-1}\circ u:\mathbb C^r\to \mathbb C^r.
\end{align*}
Then $A$ is complex-linear and, for all $z,w\in \mathbb C^r$,
\begin{align*}
(Az,Aw)_{\mathbb C^r}=h_p(u_{p,0}(Az),u_{p,0}(Aw))=h_p(uz,uw)=(z,w)_{\mathbb C^r}.
\end{align*}
Thus $A\in U(r)$ and $u=\Phi_V(p,A)$. Uniqueness follows because $u_{p,0}$ is an isomorphism.
Smoothness of $\Phi_V$ and of its inverse follows from the standard smooth structure on the complex frame bundle induced by the local frame $v_1,\dots,v_r$: in that trivialization, $\Phi_V$ is exactly the inclusion of $V\times U(r)$ into $V\times GL(r,\mathbb C)$.
We now justify the embedded-submanifold assertion for $U(r)$. Let $M_r(\mathbb C)$ denote the real vector space of all complex $r\times r$ matrices, and let $\mathcal H_r\subset M_r(\mathbb C)$ denote the real vector subspace of Hermitian complex $r\times r$ matrices. Define the smooth map
\begin{align*}
F:GL(r,\mathbb C)\to \mathcal H_r,\qquad F(A):=A^*A.
\end{align*}
Then $U(r)=F^{-1}(I_r)$. For $A\in U(r)$ and $B\in M_r(\mathbb C)$, the differential of $F$ at $A$ is
\begin{align*}
dF_A(B)=B^*A+A^*B.
\end{align*}
If $K\in\mathcal H_r$, take $B=\frac{1}{2}AK$. Since $A^*A=I_r$ and $K^*=K$, we get $dF_A(B)=K$. Thus $dF_A:M_r(\mathbb C)\to\mathcal H_r$ is surjective at every $A\in U(r)$. By the [regular value theorem](/theorems/3903), $I_r$ is a regular value of $F$ and $U(r)=F^{-1}(I_r)$ is an embedded smooth submanifold of $GL(r,\mathbb C)$. Therefore $V\times U(r)$ is an embedded smooth submanifold of $V\times GL(r,\mathbb C)$, and $\operatorname{Fr}_U(E,h)|_V$ is a smooth submanifold of $\operatorname{Fr}_{\mathbb C}(E)|_V$ locally diffeomorphic to $V\times U(r)$.
[guided]
The local frame $v_1,\dots,v_r$ gives the usual frame-bundle coordinates on $\operatorname{Fr}_{\mathbb C}(E)|_V$: a complex frame $u:\mathbb C^r\to E_p$ is represented by the unique matrix $A\in GL(r,\mathbb C)$ satisfying $u=u_{p,0}\circ A$. Under these coordinates, the unitary frames are exactly the pairs $(p,A)$ with $A\in U(r)$, because $u_{p,0}$ is already a unitary isomorphism.
It remains to check that this subset is a smooth submanifold, not merely a set-theoretic subset. Let $M_r(\mathbb C)$ denote the real vector space of all complex $r\times r$ matrices, and let $\mathcal H_r\subset M_r(\mathbb C)$ denote the real vector subspace of Hermitian complex $r\times r$ matrices. Define
\begin{align*}
F:GL(r,\mathbb C)\to \mathcal H_r,\qquad F(A):=A^*A.
\end{align*}
Then $U(r)=F^{-1}(I_r)$. To prove that this level set is smooth, compute the differential. For $A\in U(r)$ and $B\in M_r(\mathbb C)$,
\begin{align*}
dF_A(B)=B^*A+A^*B.
\end{align*}
We must show this map is onto $\mathcal H_r$. Given any Hermitian matrix $K\in\mathcal H_r$, define $B=\frac{1}{2}AK$. Since $A^*A=I_r$ and $K^*=K$, we obtain
\begin{align*}
dF_A(B)=\frac{1}{2}K^*A^*A+\frac{1}{2}A^*AK=K.
\end{align*}
Thus $dF_A$ is surjective at every $A\in U(r)$. By the regular value theorem, $I_r$ is a regular value of $F$ and $U(r)=F^{-1}(I_r)$ is an embedded smooth submanifold of $GL(r,\mathbb C)$. Consequently $V\times U(r)$ is an embedded smooth submanifold of $V\times GL(r,\mathbb C)$, and the local model identifies $\operatorname{Fr}_U(E,h)|_V$ smoothly with $V\times U(r)$ inside the complex frame bundle.
[/guided]
[/step]
[step:Check that overlap maps take values in $U(r)$]
Let $V_\alpha,V_\beta\subset M$ be open sets with smooth local $h$-unitary frames
\begin{align*}
v_{\alpha,1},\dots,v_{\alpha,r}:V_\alpha\to E
\end{align*}
and
\begin{align*}
v_{\beta,1},\dots,v_{\beta,r}:V_\beta\to E.
\end{align*}
Let
\begin{align*}
u_{\alpha,p,0}:\mathbb C^r\to E_p
\end{align*}
and
\begin{align*}
u_{\beta,p,0}:\mathbb C^r\to E_p
\end{align*}
be the associated unitary frame maps. On $V_\alpha\cap V_\beta$, define
\begin{align*}
g_{\alpha\beta}:V_\alpha\cap V_\beta\to GL(r,\mathbb C),\qquad g_{\alpha\beta}(p):=(u_{\alpha,p,0})^{-1}\circ u_{\beta,p,0}.
\end{align*}
The map $g_{\alpha\beta}$ is smooth because it is the change-of-frame matrix between two smooth local frames. Since both $u_{\alpha,p,0}$ and $u_{\beta,p,0}$ are unitary isomorphisms, for all $z,w\in \mathbb C^r$,
\begin{align*}
(g_{\alpha\beta}(p)z,g_{\alpha\beta}(p)w)_{\mathbb C^r}=h_p(u_{\beta,p,0}z,u_{\beta,p,0}w)=(z,w)_{\mathbb C^r}.
\end{align*}
Therefore $g_{\alpha\beta}(p)\in U(r)$ for every $p\in V_\alpha\cap V_\beta$.
The corresponding transition map between the local trivializations of $\operatorname{Fr}_U(E,h)$ is
\begin{align*}
(p,A)\mapsto (p,g_{\alpha\beta}(p)A),
\end{align*}
which is smooth and $U(r)$-equivariant. Thus the local identifications constructed above assemble into a smooth fibre bundle with structure group $U(r)$.
[/step]
[step:Verify the principal right action and the subbundle inclusion]
The right action of $GL(r,\mathbb C)$ on $\operatorname{Fr}_{\mathbb C}(E)$ restricts to a right action of $U(r)$ on $\operatorname{Fr}_U(E,h)$. Indeed, if $u\in \operatorname{Fr}_U(E,h)_p$ and $A\in U(r)$, then for all $z,w\in \mathbb C^r$,
\begin{align*}
h_p((u\cdot A)z,(u\cdot A)w)=h_p(u(Az),u(Aw))=(Az,Aw)_{\mathbb C^r}=(z,w)_{\mathbb C^r}.
\end{align*}
Thus $u\cdot A\in \operatorname{Fr}_U(E,h)_p$.
The action is free: if $u\cdot A=u$ for some $u\in \operatorname{Fr}_U(E,h)_p$ and $A\in U(r)$, then $u\circ A=u$, and since $u$ is an isomorphism, $A=\operatorname{id}_{\mathbb C^r}$. The action is transitive on each fibre: if $u,u'\in \operatorname{Fr}_U(E,h)_p$, then
\begin{align*}
A:=u^{-1}\circ u':\mathbb C^r\to\mathbb C^r
\end{align*}
belongs to $U(r)$ by the same inner-product computation as above, and $u'=u\cdot A$.
The local trivializations identify $\operatorname{Fr}_U(E,h)|_V$ with $V\times U(r)$ inside $\operatorname{Fr}_{\mathbb C}(E)|_V\cong V\times GL(r,\mathbb C)$, and their transition functions are $U(r)$-valued. Therefore $\operatorname{Fr}_U(E,h)\to M$ is a smooth principal $U(r)$-subbundle of $\operatorname{Fr}_{\mathbb C}(E)\to M$.
[/step]