The height of Navigation Bar in iOS 7

frameheightios7navigationbarstatusbar

I 've just created a simple iOS 7 app using the default Master Details template.

In the MasterViewController.m, viewDidAppear method, I logged for

self.navigationController.navigationBar.frame.size.height
self.navigationController.navigationBar.frame.origin.y

and received 44 and 20 accordingly. This seems weird, because from what I read, the Navigation Bar in iOS 7 should be 64 point height and start at 0 point, so that it sits underneath the Status bar. What I read are

1) iOS 7 UI Transition Guide

Because the status bar is transparent, the view behind it shows
through

2) Using Background Image in Navigation Bar

If your app uses a custom image as the background of the bar, you’ll
need to provide a “taller” image so that it extends up behind the
status bar. The height of navigation bar is changed from 44 points (88
pixels) to 64 points (128 pixels).

Best Answer

There is a difference between the navigation bar and the status bar. The confusing part is that it looks like one solid feature at the top of the screen, but the areas can actually be separated into two distinct views; a status bar and a navigation bar. The status bar spans from y=0 to y=20 points and the navigation bar spans from y=20 to y=64 points. So the navigation bar (which is where the page title and navigation buttons go) has a height of 44 points, but the status bar and navigation bar together have a total height of 64 points.

Here is a great resource that addresses this question along with a number of other sizing idiosyncrasies in iOS7: http://ivomynttinen.com/blog/the-ios-7-design-cheat-sheet/