  This is the second in a sequence of articles, in which we explore moduli
stacks of global G-shtukas, the function field analogs for Shimura varieties.
Here G is a flat affine group scheme of finite type over a smooth projective
curve C over a finite field. Global G-shtukas are generalizations of Drinfeld
shtukas and analogs of abelian varieties with additional structure. We prove
that the moduli stacks of global G-shtukas are algebraic Deligne-Mumford stacks
separated and locally of finite type. They generalize various moduli spaces
used by different authors to prove instances of the Langlands program over
function fields. In the first article we explained the relation between global
G-shtukas and local P-shtukas, which are the function field analogs of
p-divisible groups. Here P is the base change of G to the complete local ring
at a point of C. When P is smooth with connected reductive generic fiber we
proved the existence of Rapoport-Zink spaces for local P-shtukas. In the
present article we use these spaces to (partly) uniformize the moduli stacks of
global G-shtukas for smooth G with connected fibers and reductive generic
fiber. This is our main result. It has applications to the analog of the
Langlands-Rapoport conjecture for our moduli stacks.
