Understanding pedestrian perceptions and attitudes is crucial for promoting walking as a daily transportation mode for sustainable mobility and the effective development of smart cities. Pedestrian preferences, shaped by factors such as age, gender, and urban infrastructure, play a pivotal role in travel behaviors. Based on a survey study, this paper examines the impact of individual and urban factors on pedestrian perceptions and attitudes towards walking in the cities of Bologna and Porto. Results reveal that individuals generally value short, safe, and green walking routes, appreciating walking for physical activity, cost savings, and time efficiency. Disliked aspects include adverse weather conditions and walking on inadequate sidewalks. Through carrying out Chi-square statistical analysis tests, a variety of significant correlations between individual and urban variables have been revealed on what people like or dislike about walking. For instance, males, young individuals, and students were more likely to prefer short pedestrian routes, while adults and seniors favored safe and green routes. These findings can assist urban planners in identifying factors that make walking both convenient and enjoyable and in supporting sustainable urban mobility policies.