For whatever reason I really enjoy results that tell us certain schemes are affine. Here is a list of a number of results of this nature in the Stacks project (but only those which deal with schemes — there are analogues of most of these results when we look at algebraic spaces and algebraic stacks):

Tag 02O0 A scheme whose underlying space is finite discrete is affine.

Tag 01PV The nonvanishing locus of a section of a line bundle on an affine scheme is affine.

Tag 0C3A Let Y be a locally closed subscheme of an affine scheme X and assume there is an affine open U of X such that Y ∩ U is affine and such that Y ∖ U is closed in X. Then Y is affine.

Tag 04DE If X → Y is a homeomorphism onto a closed subset of the affine scheme Y then X is affine.

Tag 01XF Vanshing of higher cohomology for quasi-coherent modules implies affine.

Tag 0EBE If X is quasi-affine and H^i(X, O_X) = 0 for i > 0 then X is affine.

Tag 0EBR Suppose you have a reflexive rank 1 module L over a local ring A and a section s of L such that s^n is contained in m_{A} L^{[n]}. Then the locus where s doesn’t vanish is affine. This generalizes the case of invertible modules mentioned above.

Tag 05YU If X → Y is surjective and integral (for example finite) and X is affine, then Y is affine.

Tag 09NL If a scheme X is the union of finitely many affine closed subschemes, then X is affine.

Tag 0A28 If X is a curve and not proper, then X is affine.

Tag 0F3R If f : X → Y is a morphism of affine schemes which has a positive weighting w, then the set V of points y of Y such that the total weight over y is maximal is an affine open of Y. For example, if f is etale, then V is the maximal open of Y over which f is finite etale. Other cases where one has a weighting are discussed in Lemmas Tag 0F3D and Tag 0F3E

Tag 0EB7 The complement of a 1 dimensional closed subset of the spectrum of a 2 dimensional normal excellent Noetherian local ring is affine.

Tag 0ECD Let f : X → Y be a finite type morphism of excellent affine schemes over a field with X normal and Y regular. Then the locus V in X where f is etale is affine. (This should be true without assuming Y to be over a field.) This result is a strengthening of purity of ramification locus which itself is a result of Gabber you can find in section Tag 0EA1.

I hope you enjoy this kind of result as well! If you know addtional results of this nature, please leave a comment or send me an email. Thanks!

Matsushima’s criterion / Richardson’s theorem: A categorical quotient of an action of a linear group scheme on an affine scheme is affine if the group scheme is geometrically reductive. Conversely, a closed subgroup scheme of a general linear group (scheme) is geometrically reductive if and only if the quotient (left coset) space is affine.

Yes, I really like this one too. Thanks.

A finite type complex scheme is affine if and only if the associated complex analytic space is Stein.

Yep! Thanks!

Every quasicompact, quasiseparated scheme $X$ of dimension 0 is affine. Proof:

(1) If $U$ is affine zero-dimensional, then $\vert U\vert$ is compact Hausdorff, so each quasicompact open of $U$ is closed, in particular affine.

(2) In general, we may assume by induction that $X=U\cup V$, with $U$ and $V$ affine open. It follows fro (1) that $U\cap V$ is clopen in $U$ and affine, so $X=(U\setminus V)\coprod V$ is affine.

Complements to the above:

It follows that a quasiseparated scheme X of dimension 0 is ind-quasi-affine (in particular separated). In fact one checks that if X is reduced (i.e. absolutely flat), the canonical map to its affine hull X’ is an open immersion, and X’ is absolutely flat.

Also, all this extends to algebraic spaces, using Gruson-Raynaud (aka Tag 07ST).

Yes, this is nice. Thanks very much!