Eevee: render volumetrics behind transparent objects?

Hello - I am trying to create an animation that requires a lot of volumetric fog and smoke. In one scene I am trying to add a glass surface, but volumes are not visible through it.

Recreated example:

Screen space refraction is enabled on the material, and refraction is enabled in render settings.

From what I understand, this is a limitation of Eevee, because it uses the depth buffer to calculate screen-space refraction, and volumes do not show up in the depth buffer.

Are there any clever workarounds to this problem?


Render multiple passes? First the background with volumetrics, then foreground where is transparent object.

Is it possible to figure out in the compositor which objects are behind the transparent object? Say for example the transparent object is in the middle of the scene and the camera orbits around it - background objects would be come foreground as the camera moves around.

That should work if you render Z-pass to get distances from camera and use Z-combine node to draw them correct order.