The aim of the present study was to mask the extremely bitter taste of Tramadol HCL, an opioid analgesic, and to formulate a tablet which can rapidly disintegrate in saliva (rapidly disintegrating tablet). The crucial aspect in the formulation of mouth-dissolving tablets is to mask the bitter taste and to minimize the disintegration time. Taste masking was done using sweetening agent and D-mannitol and taste-masked pellets were prepared by extrusion spheronization technique. Prepared pellets were tested for drug content, taste evaluation in oral cavity and molecular property. Pellet shows significant taste masking, confirmed by in vitro taste evaluation; therefore, it was selected for further study. Pellets were evaluated for density, angle of repose, Carr′s index, Hausner′s ratio and sphericity while tablets were evaluated for disintegration and in vitro dissolution. A 3 2 full factorial design and statistical models were applied to optimize the effect of two factors, i.e. superdisintegrant sodium starch glycolate and taste-masking agent (D-mannitol). In this study, response surface methodology was used for designing of the experiment, generation of mathematical models and optimization study. Taste evaluation of pellets in human volunteers revealed considerable taste masking with a degree of bitterness below threshold value (2.0) within 10 s, whereas Tramadol HCl was rated intensely bitter with a score of +4 for 10 s. The size of the pellets varied from 0.895 to 1.423 mm for different batch and found to be a spherical. Disintegration time of different formulations varied from 30 to 60 s. It was observed that the responses, i.e. disintegration time and sphericity were affected by both the factors. The statistical models were validated and can be successfully used to prepare optimized taste-masked mouth-dissolving tablets of Tramadol HCl with adequate disintegration and shape.