The expansion of the ground state wave function ψ(r) of hydrogen-like ions in a Gaussian basis is derived from a discretization of a Gaussian integral transformation. This derivation involves an upper and a lower cut-off of the integration variable and the evaluation of the truncated integral by means of the trapezoid approximation, after a variable transformation to an exponentially decaying bell-shaped integrand. This automatically leads to an optimized even-tempered basis. Two criteria are studied, (a) the best approximation of ψ(r) for r = 0, (b) the best approximation for the expectation value of the Hamiltonian. In either case, the rate of convergence obeys a square-root exponential law with an error estimate , if n is the basis size. The value of the constant a depends on the considered property and on the criterion for the optimization of the basis. Simple analytic expressions for the basis parameters α and β of an even-tempered Gaussian basis are derived. The comparison of the local and global criteria gives some new and even unexpected insight. © 2012 Wiley Periodicals, Inc.