For a solution that does not involve direct constructions using partitions of unity, we can deploy Theorem 1.1 in [arXiv:1912.10544](https://arxiv.org/abs/1912.10544),
which provides an explicit formula for the classifying space of an ∞-sheaf $F$ (valued in spaces or any algebraic ∞-category) on the site of smooth manifolds.

The classifying space is
$$\def\hocolim{\mathop{\rm hocolim}}\def\op{{\rm op}}\def\gs{{\bf Δ}}\def\B{{\sf B}_\smallint}\B F=\hocolim_{n∈Δ^\op}F(\gs^n),$$
where $\gs^n$ denotes $n$-simplex considered as a smooth manifold.

In our case, $F(M)$ can be taken to be the 2-groupoid (more generally: $n$-groupoid) of principal $G$-bundles with connection over $M$.
Thus, concordance classes of principal $G$-bundles with connection over $M$ are in bijection with elements of the set $[M,\B F]$.

The ∞-sheaf $F$ admits a forgetful map $F→G$, where $G$ is defined in the same way as $F$, but without connection.
Thus, concordance classes of principal $G$-bundles over $M$ are in bijection with elements of the set $[M,\B G]$.

The map $F→G$ induces a map of classifying spaces
$$\B F=\hocolim_{n∈Δ^\op}F(\gs^n)→\B G=\hocolim_{n∈Δ^\op}G(\gs^n),$$
which can be seen to be a weak equivalence because any principal $G$-bundle over $\gs^n$ is trivial, and the space of connections on a trivial $G$-bundle up to concordance is contractible.

Thus, we have a bijection of sets $$[M,\B F]→[M,\B G]$$
induced by the map $F→G$.
Hence, any principal $G$-bundle over $M$ admits a connection.