Mosquito-borne diseases (MBDs), including those caused by flaviviruses, remain human health problems for developing and urbanizing economies. This cross-sectional study examined risks of flavivirus exposure through a survey regarding knowledge and practices of pig farmers, and serological analysis of pigs in peri-urban and suburban Hanoi city. A total of 636 pig sera from 179 pig farms in 4 districts, namely, Chuong My, Dan Phuong, Ha Dong, and Bac Tu Liem, were analyzed by a competitive ELISA designed for flavivirus antibody detection. The results indicated a low level of awareness about MBDs among pig farmers, and a high seroprevalence in pigs at 88.5% (95%CI = 85.8–90.9%). Moreover, common practices of pig owners to prevent mosquitoes at home and farm did not show a significant reduction in flavivirus exposure in pigs. At animal level, significant associations between seropositive pigs and the farms with more than 60 pigs, and the district location were found. Farm-level multivariable analysis did not identify significant risk factors for flavivirus exposure. The study suggests that improving awareness of pig owners about MBDs in Hanoi city may be warranted to reduce the risk for MBD flavivirus infections in both humans and pigs.