Background: Immune checkpoint inhibitors (ICIs) are a standard of care in multiple cancers. Only a minority benefits, thus, optimal use and treatment duration remain indistinct. While biomarkers albeit PD-L1 are scarce, declined performance status and cancer-related systemic inflammation detected by blood inflammatory markers such as C-reactive protein (CRP) have been linked to inferior prognosis. Materials and Methods: We investigated the association of limited anti-PD-(L)1 treatment duration to therapy efficacy in melanoma and non-small cell lung cancer (NSCLC) patients who received therapy in a non-curative setting in Oulu University Hospital 2014-2022. Baseline prognostic factors (e.g. ECOG, CRP, and PD-L1 for NSCLC) were collected. Progression-free (PFS), overall (OS), and IO-free survival were analyzed using the Kaplan-Meier and Cox regression methods. Results: 126 patients (NSCLC, n = 72; melanoma, n = 54) were included. Majority (n = 101) were treated in the first line. Objective response rate was 34.9%. The median (m) anti-PD-(L)1 treatment duration was 3.42 months (mo). The mPFS and mOS were 6.8 mo (CI 95% 4.4-9.3) and 19.1 mo (CI 95% 13.3-24.9). Of the baseline factors, ECOG and CRP retained their significance in multivariate analysis for PFS (HR 0.34, CI 95% 0.19-0.59; HR 0.34, CI 95% 0.22-054) and OS (HR 0.38, CI 95% 0.20-0.71; HR 0.29, CI 95% 0.17-0.49). No difference was observed in PFS (HR 1.40, CI 95% 0.68-2.90) or OS (HR 0.69, CI 95% 0.29-1.65) according to treatment duration (3-6mo vs. > 6 mo). Long median IO-free survival (10.2 months; CI 95%, 4.1-16.3) was detected. Conclusion: We characterized an anti-PD-(L)1 treated advanced NSCLC and melanoma cohort in which treatment benefit occurs irrespective of treatment duration and long-term benefit is observed off-treatment.