Atrial fibrillation (AF) is a common cardiac arrhythmia causing severe complications if left untreated. Due to its sporadic nature, early detection often requires longitudinal ambulatory electrocardiogram (ECG) screening. Recently, deep learning (DL) has gained prominence in analysing long-term ECG and automating AF detection. However, like any medical classification problem, obtaining diverse labelled ECG data for DL model training is expensive and time-consuming. This paper proposes a semi-supervised learning (SSL) based AF classification model employing a variational auto-encoder (VAE). It leverages varying amounts of labelled and unlabelled ECG data to optimise the AF detection performance on ambulatory ECG. As ambulatory contexts under free-living conditions influence ECG recordings, we incorporate context via accelerometry data and experiment with its influence on model performance. Our proposed SSL model was trained on ECG data from 72,003 unique patients and can classify between sinus rhythms, AF, and other arrhythmias. Experimental results on our unseen test dataset and the publicly available CACHET-CADB dataset clearly demonstrate the model’s generalisability, achieving an accuracy of over 91% with just 20% of the training set being labelled. With extensive experiments, our study exhibits the ability of SSL to improve AF detection from ambulatory ECG using small amounts of labelled data.