In Europe, computation of displacement demand for seismic assessment of existing buildings is essentially based on a simplified formulation of the N2 method as prescribed by Eurocode 8 (EC8). However, a lack of accuracy of the N2 method in certain conditions has been pointed out by several studies. This paper addresses the assessment of effectiveness of the N2 method in seismic displacement demand determination in non-linear domain. The objective of this work is to investigate the accuracy of the N2 method through comparison with displacement demands computed using non-linear time-history analysis (NLTHA). Results show that the original N2 method may lead to overestimation or underestimation of displacement demand predictions. This may affect results of mechanical model-based assessment of seismic vulnerability at an urban scale. Hence, the second part of this paper addresses an improvement of the N2 method formula by empirical evaluation of NLTHA results based on EC8 ground-classes. This task is formulated as a mathematical programming problem in which coefficients are obtained by minimizing the overall discrepancy between NLTHA and modified formula results. Various settings of the mathematical programming problem have been solved using a global optimization metaheuristic. An extensive comparison between the original N2 method formulation and optimized formulae highlights benefits of the strategy.