  One fundamental consequence of a scheme $X$ being proper is that the functor
classifying maps from $X$ to any other suitably nice scheme or algebraic stack
is representable by an algebraic stack. This result has been generalized by
replacing $X$ with a proper algebraic stack. We show, however, that it also
holds when $X$ is replaced by many examples of algebraic stacks which are not
proper, including many global quotient stacks. This leads us to revisit the
definition of properness for stacks.
  We introduce the notion of a formally proper morphism of stacks and study its
properties. We develop methods for establishing formal properness in a large
class of examples. Along the way, we prove strong h-descent results which hold
in the setting of derived algebraic geometry but not in classical algebraic
geometry. Our main applications are algebraicity results for mapping stacks and
the stack of coherent sheaves on a flat and formally proper stack.
