I am searched for this, but i didn\'t found the exact solution for my problem, all the answer for making blur effect shows making the blur effect on entire frame but i want
Use CAGradientLayer
UIColor *theColor = [[UIColor alloc] initWithRed:146.0/255.0 green:146.0/255.0 blue:146.0/255.0 alpha:1];
CAGradientLayer *gradientLayer = [CAGradientLayer layer];
CGRect gradientLayerFrame = theView.frame;
gradientLayerFrame.origin.x = 0;
gradientLayerFrame.origin.y = 0;
gradientLayer.frame = gradientLayerFrame;
//build the colors array for the gradient
NSArray *colors = [NSArray arrayWithObjects:
(id)[theColor CGColor],
(id)[[theColor colorWithAlphaComponent:0.9f] CGColor],
(id)[[theColor colorWithAlphaComponent:0.6f] CGColor],
(id)[[theColor colorWithAlphaComponent:0.4f] CGColor],
(id)[[theColor colorWithAlphaComponent:0.3f] CGColor],
(id)[[theColor colorWithAlphaComponent:0.1f] CGColor],
(id)[[UIColor clearColor] CGColor],
nil];
gradientLayer.colors = colors;
[yourView.layer insertSublayer:gradientLayer atIndex:0];
swift version of this code is here