OBJECTIVES: HLA-B27 is strongly associated with ankylosing spondylitis (AS) and its presence helps to confirm AS diagnosis. Due to the high HLA polymorphism and the differentiated contribution of alleles and molecules encoded by them, HLA-B*27 allele identification is relevant in the clinical follow-up, diagnosis, and treatment of this spondyloarthropathy. Inexpensive genotyping techniques with high specificity and sensitivity are of great interest in histocompatibility laboratories. This work aimed to optimize HLA-B*27 genotyping by Polymerase Chain Reaction Sequence-specific Primer (PCR-SSP), which is an accessible and inexpensive technique. METHODS: The PCR-SSP was standardized using 26 HLA-B*27 positive and 3 HLA-B*27 negative samples previously defined by Polymerase Chain Reaction Sequence-specific Oligonucleotide Probes (PCR-SSOP) (medium resolution, One Lambda®) and primers described by Duangchanchot et al. (2009). For validating the technique, 397 samples were genotyped using PCR-SSP as well as PCR-SSOP. RESULTS: The PCR-SSP technique was standardized for identifying the alleles HLA-B*27:02, HLA-B*27:CAFRW (05/13/16/17/28/37/38/39/42), HLA-B*27:CAFRZ (08/26/40), HLA-B*27:09 and HLA-B*27:12, which were found in 90 positive samples (22.67%). There was 100% agreement between the two techniques for heterozygous samples; however, two homozygous samples could not be detected by PCR-SSP. CONCLUSION: The HLA-B*27 genotyping using PCR-SSP, an easy-to-use, specific, and affordable technique, was optimized for heterozygous samples. This technique may contribute to AS diagnosis.