This paper is concerned with the design of optimal quality control and maintenance policies based on on-line sampling plans. This paper analyzes the performance of an inspection and maintenance policy that begins 100% sampling of a production lot after producing n parts and the initiates a preventive/corrective maintenance activity when the fraction of bad parts in the sample reaches a given threshold f*. The decision maker must select n and f* to achieve an economic trade-off among the costs of sampling, inspection, maintenance, scrap, and lost production. This paper derives the fundamental performance measures required to assess these costs as a function of n and f*. A numerical study using hypothetical data is used to illustrate the application of the model. Sensitivity analyses indicate the effects of changes in key input parameters on the optimal solution. This research shows the optimal policy is sensitive to some input parameters, such as the input rate of parts, the process switch rate, the quality control cost, and the probability of producing defective parts. Consequently, more effort should be made to obtain accurate estimates of these parameters. Moreover, the optimal quality control and maintenance policy is insensitive to the variance of the process stoppage time. Hence, even though one might have difficulty in estimating or specifying the probability distribution functions of the process inspection time, the preventive maintenance time, or the repair maintenance time, the optimal final decision will not be affected greatly as long as the mean values of these times are available. Finally, when the design of a process capacity is considered, it is important to take into account the requirements for quality control, process inspection, and process maintenance.