This paper derives Hamilton-Jacobi equation (HJE) in Hilbert space for optimal control of stochastic distributed parameter systems (SDPSs) governed by partial differential equations (SPDEs) subject to both state-dependent and additive stochastic disturbances. First, nonlinear SDPSs are transformed to stochastic evolution systems (SESs), which are governed by stochastic ordinary differential equations (SODEs) in Hilbert space, using functional analysis. Second, the Hamilton-Jacobi equation (HJE), of which the solution results in an optimal control law, is derived. Third, a problem of optimal control of linear SDPSs, which include the air pollution process, with a quadratic cost functional is addressed as an application of the HJE. After, the control design is done, the SESs are transformed back to Euclidean space for implementation.