This paper considers the following kind of stochastic optimal control problems:
where is the control variable with values in a convex subset of , is the state variable with values in , is a standard -valued Wiener process, and are given mappings, which are dependent on the histories and the present state of , i.e. defined on the functional space and nonanticipative.
A necessary condition, called the maximum principle, for such optimal control problems is obtained; the adjoint equation, which seems to be new in form, is derived and the existence and uniqueness of the solution of that equation are proved. The main idea to treat the adjoint equation consists in using the method developed in a work of the authors on the maximum principle for semilinear stochastic evolution control systems. This is based on the idea of using a feedback law and on the stochastic Fubini theorem.