We derive a general equation for the depletion thickness δ next to a flat wall in a solution of nonadsorbing polymer, which is easily extended to spherical geometry. This equation has the simple form δ-2 = δ0 -2 + ξ-2. Here, δ0 is the value of δ in the limit of infinite dilution, which depends only on the chain length: δ0 = 2R/√π, where R is the radius of gyration of the polymer. The parameter ξ is a correlation length in solution, which depends on the polymer concentration φb and the solvency χ, but not on the chain length. We use a mean-field form of ξ = ξ(χ,φb) which provides a smooth crossover from good to Θ solvency conditions. We show that the depletion thickness is actually a generalized bulk solution correlation length which does depend on chain length. In all cases the profile for a flat wall is given by ρ = φ/φb = tanhi2(z/δ). The extension to a sphere of radius a is also very simple: ρs = [z/a + tanh(z/δ)]2/[z/a + 1]2. The analytical results are compared to numerical self-consistent-field computations, whereby the segment-wall repulsion in the lattice model is chosen in accordance with the boundary condition ρ(0) = 0 in the continuum model. The agreement is nearly perfect for good solvents and large particles. For a Θ solvent our simple analytical model overestimates δ slightly; in this case the tanh2 profile is not strictly valid, and we derive a corrected analytical form. For smaller particles, also a slight overestimation of the width of the depletion zone is found. However, in all cases the trends are predicted very well. Our simple equations allow, in principle, analytical expressions for the surface tension, for the distribution coefficient in size-exclusion chromatography, and for interaction potentials and phase diagrams of colloids with nonadsorbing polymer.