Artificial neural network (ANN) is an information processing paradigm that loosely models the thinking patterns of the human brain with specifications such as real-time learning, self-adaption, and self-organization. The learning process of ANNs is complex and tackles shortcomings such as a slow convergence rate, learning time-consuming, and local minimum trapping, especially when using gradient-based optimization techniques. Although many metaheuristics have been proposed to arm ANN and solve these weaknesses, ANN learning still needs solution quality. Therefore, this study proposes an evolutionary crow search algorithm (ECSA) to optimize the hyperparameters of ANNs for diagnosing chronic diseases. ECSA introduces an evolutionary search strategy, self-adaptive adaptive flight length, and an interactive memory mechanism to alleviate the canonical crow search algorithm's shortcomings. The evolutionary search strategy and self-adaptive flight length provide a meaningful search strategy in which crows effectively explore and exploit problem spaces by maintaining population diversity. During the search process, the interactive memory mechanism records the best solution obtained during optimization. The performance of ECSA was evaluated and compared with well-known metaheuristic algorithms in terms of local and global search abilities, local optima avoidance, and convergence speed towards the promising area. Then, the results were statistically analyzed. Ultimately, the effectiveness of an adaptation of ECSA named ECSA-MLP for optimizing hyperparameters of the multilayer perceptron network for diagnosing diseases including coronavirus, breast cancer, diabetes, cardiovascular, cervical cancer, Parkinson's, mammography, and acute inflammation was compared with state-of-the-art competitor algorithms. The experimental results indicated the superiority of ECSA over competitor algorithms in optimizing the network.