I just installed iOS 7.1.1, Apple's latest operating system (as of the end of June 2014). The built-in Compass app has a hidden feature. Once you open Compass, swipe from right to left and you'll see a leveling screen. When the two circles line up, it will show 0 degrees and the screen will turn green. If the two circles don't line up, it will show you the number of degrees that it's off by. It even works on my old iPhone 4.
The app and the upgrade to the operating system are free.
There's a video of it on YouTube: