With the recent advances in immunotherapy, especially programmed cell death protein 1 (PD-1) inhibitors, the treatment of hepatocellular carcinoma (HCC) patients has entered a new stage. However, few reports have focused on spontaneous bacterial peritonitis (SBP) after PD-1 inhibitor treatment of intermediate-to advanced-stage HCC. In this article, we report two clinical cases of SBP after successful PD-1 inhibitor therapy. The patient's condition was assessed as a complete response (CR) according to the mRECIST criteria. Based on these two cases, we found that patients with large or giant HCC who have large tumour diameter should be closely monitored for SBP after successful PD-1 inhibitor therapy, especially when the imaging shows the rapid development of marked necrosis and depression at the tumour site. Early and active treatment is necessary to reduce the suffering caused by SBP.