In this paper, a Krein space approach to finite horizon H <sub xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">∞</sub> filtering is proposed for a class of affine nonlinear discrete-time systems. It is shown that the problem of H <sub xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">∞</sub> nonlinear filtering can be converted into a minimum of an indefinite quadratic form. Hence, a relationship between H <sub xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">∞</sub> nonlinear filter in Hilbert space and nonlinear estimation in Krein space is established. By using first-order Taylor approximation and Krein space projection, a sufficient and necessary condition for the minimum is derived. Moreover, a feasible solution of the H <sub xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">∞</sub> nonlinear filter can be obtained by recursively computing Riccati recursions. Finally, a numerical example and one kind of integration filter are used to demonstrate the effectiveness of the proposed method.