Quantitative theory of the particle-interface interaction across a nonpolar medium is developed. We consider a spherical dielectric particle (phase 1), which is immersed in a nonpolar medium (phase 2), near its boundary with a third dielectric medium (phase 3). The interaction originates from electric charges at the particle surface (e.g., the surface of a silica particle immersed in oil). The theoretical problem is solved exactly, in terms of Legendre polynomials, for arbitrary values of the dielectric constants of the three phases. As a result, expressions for calculating the interaction force and energy are derived. These expressions generalize the known theory of the electrostatic image force (acing on point charges) to the case of particles that have finite size and uniform surface charge density. For typical parameter values (silica or glass particles immersed in tetradecane), the image-force interaction becomes significant for particles of radius R > 30 nm. At fixed relative particle-to-interface distance, the force increases with the cube of the particle radius. In general, this is a strong and long-range interaction. For micrometer-sized particles, the interaction energy could be on the order of 10(5) k(B)T at close contact, and, in addition, the interaction range could be about 10(5) particle radii. The sign of the interaction depends on the difference between the dielectric constants of phases 2 and 3. When phase 3 has a smaller dielectric constant (e.g., air), the interface repels the particle. In contrast, when phase 3 has a greater dielectric constant (e.g., water), the interaction is attractive. Especially, water drops attract charged hydrophobic particles dispersed in the oily phase, and thus favor the formation of reverse particle-stabilized (Pickering) emulsions. The particle-interface interaction across the oily phase is insensitive to the concentration of electrolyte in the third, aqueous phase.