Dragi Anevsk The monotone rearrangement algorithm Abstract Hardy, Littlewood and Polya presented the monotone rearrangement algorithm as a tool in analysis in their classic book "Inequalities". The algorithm can be seen as a sorting device for real valued functions on (a subset of) the real line. We propose to use the algorithm as a general tool for nonparametric inference under order restrictions. We derive limit distributions for the obtained estimators, that hold for various dependence situations such as i.i.d. data, weakly dependent mixing data and long range dependent data. Two applications are given, to regression function and density function estimation under monotonicity.