A zeolitic imidazolate framework-8 (ZIF-8) nanocrystal coated capillary is shown not only to have a strong ability to sieve branched alkanes from linear alkane isomers owing to the narrow pore windows but also to offer excellent features for high-resolution gas chromatographic separation of linear alkanes due to van der Waals interaction between linear alkanes and the hydrophobic inner surfaces of the micropores. This makes the ZIF-8 coated capillary very promising for the specific adsorption and separation of alkanes in complicated matrices.