Detection of atrial fibrillation involves detecting a plurality of ventricular events and obtaining a series of probabilities of AF, each corresponding to a probability of AF for a different beat window having a plurality of ventricular events. AF onset is detected when one or each of a plurality of consecutive AF probabilities satisfies an AF trigger threshold. AF termination is detected when one or each of a plurality of consecutive AF probabilities does not satisfy the AF trigger threshold. A probability of AF is obtained using one or more of a probability of AF that is based on the presence of irregularity of the ventricular events (PMC) a probability of AF that is based on variances of R-R intervals of the ventricular events (PVAR) and/or a combination of these probabilities (PCOMBINED).