Background.Integrating mental health care into HIV services is critical to addressing the high unmet treatment needs for people living with HIV and comorbid major depressive disorder. Introducing routine mental health screening at the primary health care level is a much needed diagonal approach to enhancing HIV care. In low-resource settings with a shortage of mental health care providers, eMental Health may provide a novel opportunity to attenuate this treatment gap and strengthen the health system.Objective.To conduct formative health systems research on the implementation of routine depression screening using a digital tool – Mood in Retroviral Positive Individuals Application Monitoring (MIR + IAM) – in an HIV primary care setting in South Africa.Methods.A Theory of Change (ToC) approach was utilised through individual and group session interviews to design an intervention that is embedded in the local context. Ten experts and local stakeholders were selected from the UK and South Africa. Data were analysed thematically using Atlas.ti to identify interventions, assumptions, barriers and facilitators of implementation.Findings.The participants considered digital depression screening in HIV care services relevant for the improvement of mental health in this population. The six main themes identified from the ToC process were: (1) user experience including acceptability by patients, issues of patient privacy and digital literacy, and the need for a patient-centred tool; (2) benefits of the digital tool for data collection and health promotion; (3) availability of treatment after diagnosis; (4) human and physical resource capacity of primary health care; (5) training for lay health care workers; and (6) demonstration of the intervention's usefulness to generate interest from decision-makers.Conclusion.Digital depression screening coupled with routine mental health data collection and analysis in HIV care is an applicable service that could improve the mental and physical health outcomes of this population. Careful consideration of the local health system capacity, including both workers and patients, is required. Future research to refine this intervention should focus on service users, government stakeholders and funders.