The NW (Needleman-Wunsch) algorithm is a method of sequence alignment in bioinformatics. The NW algorithm can be applied for global sequence alignment, which is a way of arranging the sequences of DNA to identify regions of similarity. However, the NW algorithm requires a huge number of calculations compared with the SW (Smith-Waterman) algorithm. Many studies have focused on analyzing the output of multiple sequences quickly in three dimensions. However, such methods cannot obtain similarities for whole sequences. In this article, we extend the NW algorithm to three dimensions. The proposed method is expected to provide a fast analysis of high precision data sequences.