The calculated distance (air line) between Nürnberg and Forchheim is approximately 18 miles respectively 29 kilometers.
By car or train, the actual journey to Forchheim is certainly longer, as only the direct route (as the crow flies) between Nürnberg and Forchheim has been calculated here.