Aims: A short sequence of viral protein/ peptide could be used as a potential vaccine to treat coronavirus. Considering all variants of concern (VOC), designing a peptide vaccine for severe acute respiratory syndrome coronavirus 2 (SARS CoV-2) is a challenging task for scientists. Materials & Methods: In this study, an epitope-containing vaccine peptide in nonstructural protein 4 (nsp4) of SARS-CoV-2 was predicted. Using a modified method for both B and T cell epitope prediction (verified by molecular docking studies), linear B and T cell epitopes of nsp4 protein were predicted. Predicted epitopes were analyzed with population coverage calculation and epitope conservancy analysis. Findings: The short peptide sequence 74 QRGGSYTNDKA 84 was selected as B-cell epitope by considering the scores of surface accessibility, hydrophilicity, and beta turn for each amino acid residue. Similarly, the peptide sequences 359 FLAHIQWMV 367 and 359 FLAHIQWVMFTPLV 373 were predicted as T cell epitopes for MHC-I and MHC-II molecules. These two potential epitopes could favor HLA-A*02:01 and HLA-DRB*01:01 as MHC allelic proteins with the lowest IC 50 values, respectively. No amino acid mutations were observed in GISAID (global initiative on sharing all influenza data) database for alpha, beta, gamma, and delta variants of concerns. Among seven amino acid point mutations in nsp4 protein of omicron variant, none were present in the peptide sequences of the predicted epitopes. Conclusion: Short peptide sequences could be predicted as vaccines to prevent infections caused by coronavirus variants of concerns.