We seek to investigate the multifaceted factors influencing secondary infections in patients with multidrug-resistant Gram-negative bacteria (MDR-GNB) colonization or infection post-hospitalization. A total of 100 patients with MDR-GNB colonization or infection were retrospectively reviewed, encompassing those admitted to both the general ward and intensive care unit of our hospital from August 2021 to December 2022. Patients were categorized into the control group (non-nosocomial infection, n = 56) and the observation group (nosocomial infection, n = 44) based on the occurrence of nosocomial infection during hospitalization. Clinical data were compared between the two groups, including the distribution and antibiotic sensitivity of MDR-GNB before nosocomial infection. Significant differences were observed between the two groups in terms of age, underlying diseases, immune status, length of stay, and invasive medical procedures (P < 0.05). The observation group also had fewer patients practicing optimized hygiene, strict isolation, and antibiotic control than the control group (P < 0.05). Factors influencing the risk of secondary infection after hospitalization in patients colonized or infected with MDR-GNB included patient age, underlying diseases, immune status, length of hospitalization, medical invasive procedures, optimized hygiene, strict isolation, and antibiotic control (P < 0.05). The length of hospitalization and treatment cost in the observation group were higher than those in the control group (P < 0.05). This study comprehensively analyzes the intricate mechanisms of secondary infections in patients with MDR-GNB infections post-hospitalization. Key factors influencing infection risk include patient age, underlying diseases, immune status, length of hospitalization, medical invasive procedures, optimized hygiene, strict isolation, and antibiotic control.