This paper proposes the discrete wavelet transform (DWT) block-based scrambling algorithm used for medical image encryption which applies the edge maps extracted from a source image. The method comprises three major stages: DWT-plane decomposition, generation of edge map sequences, and DWT-level scrambling. In the first stage, the original medical images are decomposed into numerous DWT-planes. In the second stage, the deriche edge detector method has been presented to estimate the edge maps, which must be a similar size to the DWT-bit scales. The DWT-level scrambling has been used to isolate the neighboring pixels into various rows and columns, thus it weakens the strong correlation among the neighboring pixels efficiently. This proposed method shows the Number of Pixel Change Rate as 99.592% and Unified Average Hanged Intensity of 34.268%. Furthermore, simulations and security analysis shows strong resistance to different security attacks and perform better other conventional methods. © 2020, Springer-Verlag GmbH Germany, part of Springer Nature.