NSString *text = self.textView.text; CGSize size = [text sizeWithAttributes:@{your font} constrainedToSize:textViewSize]; UIFont *font = your font; NSInteger lines = (NSInteger)(size.height / font.lineHeight);