Episodes of patient-ventilator asynchrony (PVA) occur during acute and chronic non-invasive positive pressure ventilation (NIV). In long-term NIV, description and quantification of PVA is not standardised, thus limiting assessment of its clinical impact. The present report provides a framework for a systematic analysis of polygraphic recordings of patients under NIV for the detection and classification of PVA validated by bench testing. The algorithm described uses two different time windows: rate asynchrony and intracycle asynchrony. This approach should facilitate further studies on prevalence and clinical impact of PVA in long-term NIV.