If X is a geodesic metric space and x1,x2,x3 ∈ X, a geodesic triangleT = {x1,x2,x3} is the union of the three geodesics [x1x2], [x2x3] and [x3x1] in X. The space X is δ-hyperbolic (in the Gromov sense) if any side of T is contained in a δ-neighborhood of the union of the two other sides, for every geodesic triangle T in X. If X is hyperbolic, we denote by δ(X) the sharp hyperbolicity constant of X, i.e., \({\delta}(X)=\inf\{{\delta}\ge 0: \, X \, \text{is $\delta$-hyperbolic}\}. \) In this paper we study the hyperbolicity of median graphs and we also obtain some results about general hyperbolic graphs. In particular, we prove that a median graph is hyperbolic if and only if its bigons are thin.