We investigate the possibility of spontaneous scalarization of static, spherically symmetric, and asymptotically flat black holes (BHs) in the Horndeski theory. Spontaneous scalarization of BHs is a phenomenon that the scalar field spontaneously obtains a nontrivial profile in the vicinity of the event horizon via the nonminimal couplings and eventually the BH possesses a scalar charge. In the theory in which spontaneous scalarization takes place, the Schwarzschild solution with a trivial profile of the scalar field exhibits a tachyonic instability in the vicinity of the event horizon, and evolves into a hairy BH solution. Our analysis will extend the previous studies about the Einstein-scalar-Gauss-Bonnet (GB) theory to other classes of the Horndeski theory. First, we clarify the conditions for the existence of the vanishing scalar field solution $\phi=0$ on top of the Schwarzschild spacetime, and we apply them to each individual generalized galileon coupling. For each coupling, we choose the coupling function with minimal power of $\phi$ and $X:=-(1/2)g^{\mu\nu}\partial_\mu\phi\partial_\nu\phi$ that satisfies the above condition, which leaves nonzero and finite imprints in the radial perturbation of the scalar field. Second, we investigate the radial perturbation of the scalar field about the $\phi=0$ solution on top of the Schwarzschild spacetime. While each individual generalized galileon coupling except for a generalized quartic coupling does not satisfy the hyperbolicity condition or realize a tachyonic instability of the Schwarzschild spacetime by itself, a generalized quartic coupling can realize it in the intermediate length scales outside the event horizon. Finally, we investigate a model with generalized quartic and quintic galileon couplings, which includes the Einstein-scalar-GB theory as the special case.